[LLVMbugs] [Bug 12767] New: The preprocessor doesn't inhibit expansion when concatenating with an empty token
bugzilla-daemon at llvm.org
bugzilla-daemon at llvm.org
Tue May 8 11:05:25 PDT 2012
http://llvm.org/bugs/show_bug.cgi?id=12767
Bug #: 12767
Summary: The preprocessor doesn't inhibit expansion when
concatenating with an empty token
Product: clang
Version: 3.0
Platform: All
OS/Version: All
Status: NEW
Severity: enhancement
Priority: P
Component: -New Bugs
AssignedTo: unassignedclangbugs at nondot.org
ReportedBy: pfultz2 at yahoo.com
CC: llvmbugs at cs.uiuc.edu
Classification: Unclassified
The preprocessor doesn't inhibit expansion when concatenating with an empty
token.
Here an example:
#define EMPTY()
#define DEFER(id) id EMPTY()
#define A(p, ...) p ## __VA_ARGS__ // should inhibit expansion of ...
#define B(p, ...) p __VA_ARGS__
#define TEST() 123
A(, DEFER(TEST)()) // should be TEST (), but clang expands to 123
B(, DEFER(TEST)()) // should be 123
--
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
More information about the llvm-bugs
mailing list