From: Camille G. <k10...@wa...> - 2010-07-15 14:17:32
|
Hello, I'm using SWIG Preprocessor for writing wrapper code, and I didn't manage to get an unique identifier using __LINE__. I tried the following : >#define CAT_HELP(a,b) a##b >#define CAT(a,b) CAT_HELP(a,b) >#define UNIQUE_ID(a) CAT(a,__LINE__) >UNIQUE_ID(foo) And the only output I got was "foo__LINE__" (using both swig 1.3 and 2.0), whereas gcc gives "foo4". Is there a known workaround ? Thanks. C. GILLOT |