Synopsis - Issue Tracker

Message379

Author hkaiser
Recipients dave, hkaiser, stefan
Date 2005-03-09.14:18:19
Content
All I can say is, that Wave produces XY as well, which makes me believe that this is correct ;-)

But seriously, I don't see any reason why the second CAT shouldn't be expanded because the CAT macro is disabled only during its expansion (disabling ends on the first ')') and it is re-enabled afterwards. To illustrate the actual expansion process I've attached the expansion trace produced by Wave from the given code snippet:

file test.cpp:
#pragma wave trace (on)
#define CAT(a, b)    CAT_(a, b)
#define CAT_(a, b)   a ## b
#define AB(x, y)     CAT(x, y)
CAT(A, B)(X, Y)

command line:
wave --traceto trace.txt test.cpp

Regards Hartmut
Files
File nameUploaded
trace.txt hkaiser, 2005-03-09.14:18:20
History
Date User Action Args
2005-03-09 14:18:21hkaisersetmessageid: <1110377900.43.0.447176611995.bug60@synopsis.fresco.org>
2005-03-09 14:18:21hkaisersetrecipients: + hkaiser, dave, stefan
2005-03-09 14:18:20hkaiserlinkbug60 messages
2005-03-09 14:18:20hkaisercreate