summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CodeGenModule.cpp
diff options
context:
space:
mode:
authorJordan Rose <jordan_rose@apple.com>2013-03-05 22:51:04 +0000
committerJordan Rose <jordan_rose@apple.com>2013-03-05 22:51:04 +0000
commit864b8107397b5f6b18b45cd51249d2a7634e2b56 (patch)
tree762b0ce78e8ffea3681220b5acd165604f118262 /clang/lib/CodeGen/CodeGenModule.cpp
parent56fe4066e589ff76051d9af0344f931d7adf628a (diff)
downloadbcm5719-llvm-864b8107397b5f6b18b45cd51249d2a7634e2b56.tar.gz
bcm5719-llvm-864b8107397b5f6b18b45cd51249d2a7634e2b56.zip
Preprocessor: don't consider // to be a line comment in -E -std=c89 mode.
It's beneficial when compiling to treat // as the start of a line comment even in -std=c89 mode, since it's not valid C code (with a few rare exceptions) and is usually intended as such. We emit a pedantic warning and then continue on as if line comments were enabled. This has been our behavior for quite some time. However, people use the preprocessor for things besides C source files. In today's prompting example, the input contains (unquoted) URLs, which contain // but should still be preserved. This change instructs the lexer to treat // as a plain token if Clang is in C90 mode and generating preprocessed output rather than actually compiling. <rdar://problem/13338743> llvm-svn: 176526
Diffstat (limited to 'clang/lib/CodeGen/CodeGenModule.cpp')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud