llvm-project/clang/tools
Alexander Kornienko 1e80887d63 Use lexing mode based on FormatStyle.Standard.
Summary:
Some valid pre-C++11 constructs change meaning when lexed in C++11
mode, e.g.
#define x(_a) printf("foo"_a);
(example from http://llvm.org/bugs/show_bug.cgi?id=16342). "foo"_a is treated as
a user-defined string literal when parsed in C++11 mode.
In order to deal with this correctly, we need to set lexing mode according to
which standard the code conforms to. We already have a configuration value for
this (FormatStyle.Standard), which seems to be appropriate to use in this case
as well.

Reviewers: klimek

CC: cfe-commits, gribozavr

Differential Revision: http://llvm-reviews.chandlerc.com/D1028

llvm-svn: 185149
2013-06-28 12:51:24 +00:00
..
arcmt-test Remove dead include. 2013-06-26 12:49:58 +00:00
c-arcmt-test [Driver] Refactor clang driver to use LLVM's Option library 2013-06-14 17:17:23 +00:00
c-index-test [Driver] Refactor clang driver to use LLVM's Option library 2013-06-14 17:17:23 +00:00
clang-check [Driver] Refactor clang driver to use LLVM's Option library 2013-06-14 17:17:23 +00:00
clang-format Use lexing mode based on FormatStyle.Standard. 2013-06-28 12:51:24 +00:00
diag-build Add new tool 'diag-build' for showing enabled warnings in a project. 2012-06-18 21:31:37 +00:00
diagtool [Driver] Refactor clang driver to use LLVM's Option library 2013-06-14 17:17:23 +00:00
driver Don't use PathV1.h in cc1as_main.cpp. 2013-06-26 12:48:34 +00:00
libclang Don't use PathV1.h in CIndexCodeCompletion.cpp. 2013-06-26 12:54:23 +00:00
scan-build [analyzer] Add --override-compiler option to scan-build. 2013-05-31 02:31:07 +00:00
scan-view [analyzer] scan-view: don't ever serve absolute paths. 2013-04-29 17:23:06 +00:00
CMakeLists.txt Add clang-format binary to cfe. 2013-03-20 09:53:23 +00:00
Makefile Reorder builds based by ordering. 2013-06-25 00:21:29 +00:00