summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/UnreachableBlockElim.cpp
diff options
context:
space:
mode:
authorMartin Probst <martin@probst.io>2017-11-25 09:33:47 +0000
committerMartin Probst <martin@probst.io>2017-11-25 09:33:47 +0000
commite8e27ca866d89a40639c8592032ca21fdf4848bf (patch)
treea55dbf88ab7e8dc9a7d5683fb1bf1177737b0f43 /llvm/lib/CodeGen/UnreachableBlockElim.cpp
parent6c38ef90fdd12917d9401bbaff95ebfc12a08491 (diff)
downloadbcm5719-llvm-e8e27ca866d89a40639c8592032ca21fdf4848bf.tar.gz
bcm5719-llvm-e8e27ca866d89a40639c8592032ca21fdf4848bf.zip
clang-format: [JS] handle semis in generic types.
Summary: TypeScript generic type arguments can contain object (literal) types, which in turn can contain semicolons: const x: Array<{a: number; b: string;} = []; Previously, clang-format would incorrectly categorize the braced list as a block and terminate the line at the openening `{`, and then format the entire expression badly. With this change, clang-format recognizes `<` preceding a `{` as introducing a type expression. In JS, `<` comparison with an object literal can never be true, so the chance of introducing false positives here is very low. Reviewers: djasper Subscribers: klimek, cfe-commits Differential Revision: https://reviews.llvm.org/D40424 llvm-svn: 318975
Diffstat (limited to 'llvm/lib/CodeGen/UnreachableBlockElim.cpp')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud