llvm-project/clang/unittests/Format
Martin Probst 6181da4796 clang-format: [JS] nested and tagged template strings.
JavaScript template strings can be nested arbitrarily:

    foo = `text ${es.map(e => { return `<${e}>`; })} text`;

This change lexes nested template strings using a stack of lexer states to
correctly switch back to template string lexing on closing braces.

Also, reuse the same stack for the token-stashed logic.

Reviewers: djasper

Subscribers: cfe-commits, klimek

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

llvm-svn: 279727
2016-08-25 10:13:21 +00:00
..
CMakeLists.txt clang-format: [JS] sort ES6 imports. 2016-05-20 11:24:24 +00:00
CleanupTest.cpp Implement tooling::Replacements as a class. 2016-08-01 10:16:37 +00:00
FormatTest.cpp clang-format: Add SpaceAfterTemplate 2016-08-09 14:24:40 +00:00
FormatTestJS.cpp clang-format: [JS] nested and tagged template strings. 2016-08-25 10:13:21 +00:00
FormatTestJava.cpp Make tooling::applyAllReplacements return llvm::Expected<string> instead of empty string to indicate potential error. 2016-07-11 13:53:12 +00:00
FormatTestProto.cpp Make tooling::applyAllReplacements return llvm::Expected<string> instead of empty string to indicate potential error. 2016-07-11 13:53:12 +00:00
FormatTestSelective.cpp Make tooling::applyAllReplacements return llvm::Expected<string> instead of empty string to indicate potential error. 2016-07-11 13:53:12 +00:00
FormatTestUtils.h Header guard canonicalization, clang part. 2014-08-13 16:25:19 +00:00
SortImportsTestJS.cpp Make tooling::applyAllReplacements return llvm::Expected<string> instead of empty string to indicate potential error. 2016-07-11 13:53:12 +00:00
SortIncludesTest.cpp Make clang-format remove duplicate headers when sorting #includes. 2016-08-10 09:32:23 +00:00