Don't allow #include (and its friends #import, #include_next and
#__include_macros) in the arguments of a function-style macro. Directives in the arguments of such macros have undefined behaviour, and GCC does not correctly support these cases. In some situations, this can lead to better diagnostics. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@146765 91177308-0d34-0410-b5e6-96231b3b80d8
Showing
- include/clang/Basic/DiagnosticLexKinds.td 3 additions, 1 deletioninclude/clang/Basic/DiagnosticLexKinds.td
- lib/Lex/PPDirectives.cpp 18 additions, 2 deletionslib/Lex/PPDirectives.cpp
- test/Preprocessor/macro_arg_directive.c 20 additions, 0 deletionstest/Preprocessor/macro_arg_directive.c
- test/Preprocessor/macro_arg_directive.h 9 additions, 0 deletionstest/Preprocessor/macro_arg_directive.h
Loading
Please register or sign in to comment