add gensym macro
This commit is contained in:
parent
5080294472
commit
c789200f5b
|
@ -42,6 +42,14 @@ extern "C" {
|
|||
#define FALLTHROUGH ((void)0)
|
||||
#define UNUSED(v) ((void)(v))
|
||||
|
||||
#define GENSYM2__(x,y) x##y
|
||||
#define GENSYM1__(x,y) GENSYM2__(x,y)
|
||||
#if defined(__COUNTER__)
|
||||
# define GENSYM(x) GENSYM1__(x,__COUNTER__)
|
||||
#else
|
||||
# define GENSYM(x) GENSYM1__(x,__LINE__)
|
||||
#endif
|
||||
|
||||
#include "config.h"
|
||||
#include "picrin/value.h"
|
||||
|
||||
|
|
Loading…
Reference in New Issue