summaryrefslogtreecommitdiff
path: root/clang/test/Parser/compound-token-split.cpp
AgeCommit message (Collapse)Author
2020-08-31Fix -Wcompound-token-split to give the same warnings under -ERichard Smith
-frewrite-includes. Remove the special-case (and highly implausible) diagnostic for a compound token that crosses a file boundary, and instead model that case the same as a compound token separated by whitespace, so that file transitions and presumed file transitions behave the same way.
2020-08-31Remove -Wcompound-token-split-by-space from -Wall.Richard Smith
Use of a linebreak between the `(` and `{` in a GNU statement-expression appears to be too common to include this warning in -Wall -- this occurs in some Linux kernel headers, for example.
2020-08-28Add new warning for compound punctuation tokens that are split across macro ↵Richard Smith
expansions or split by whitespace. For example: #define FOO(x) (x) FOO({}); ... forms a statement-expression after macro expansion. This warning applies to '({' and '})' delimiting statement-expressions, '[[' and ']]' delimiting attributes, and '::*' introducing a pointer-to-member. The warning for forming these compound tokens across macro expansions (or across files!) is enabled by default; the warning for whitespace within the tokens is not, but is included in -Wall. Differential Revision: https://reviews.llvm.org/D86751