OSDN Git Service

Restore GNU , ## __VA_ARGS__ behavior in MSVC mode
authorHarald van Dijk <harald@gigawatt.nl>
Mon, 25 Jan 2021 22:34:49 +0000 (22:34 +0000)
committerHarald van Dijk <harald@gigawatt.nl>
Mon, 25 Jan 2021 22:34:49 +0000 (22:34 +0000)
commitb43c26d036dcbf7a6881f39e4434cf059364022a
treeec3c8a1bb6541ffea56899a424cd1e3cd4336beb
parent1fba21778f84f266f7d32153c88e59e1900fbe5b
Restore GNU , ## __VA_ARGS__ behavior in MSVC mode

As noted in D91913, MSVC implements the GNU behavior for
, ## __VA_ARGS__ as well. Do the same when `-fms-compatibility` is used.

Reviewed By: rsmith

Differential Revision: https://reviews.llvm.org/D95392
clang/lib/Lex/TokenLexer.cpp
clang/test/Preprocessor/macro_fn_comma_swallow2.c