Skip to content
Snippets Groups Projects
Commit 2731f958 authored by Martin Probst's avatar Martin Probst
Browse files

clang-format: [JS] prevent wraps before class members.

Summary: In JavaScript/TypeScript, class member definitions that use modifiers can be subject to Automatic Semicolon Insertion (ASI). For example, "class X { get \n foo }" defines a property called "get" and a property called "foo", both with no type annotation. This change prevents wrapping after the modifier keywords (visibility modifiers, static, get and set) to prevent accidental ASI.

Reviewers: djasper, bkramer

Subscribers: klimek, cfe-commits

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

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@301397 91177308-0d34-0410-b5e6-96231b3b80d8
parent a530e823
No related branches found
No related tags found
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment