HomePhabricator

clang-format: [JS] detect C++ keywords.

Authored by mprobst on Apr 2 2020, 7:53 AM.

Description

clang-format: [JS] detect C++ keywords.

Summary:
C++ defines a number of keywords that are regular identifiers in
JavaScript, e.g. concept:

const concept = 1; // legit JS

This change expands the existing IsJavaScriptIdentifier(Tok) function
to return false for C++ keywords that aren't keywords in JS.

Reviewers: krasimir

Subscribers: jfb, cfe-commits

Tags: #clang

Differential Revision: https://reviews.llvm.org/D77311

Details

Committed
mprobstApr 3 2020, 5:23 AM
Differential Revision
D77311: clang-format: [JS] detect C++ keywords.
Parents
rG0718e3ae31b0: [mlir][vulkan-runner] Add support for 3D memrefs.
Branches
Unknown
Tags
Unknown