现在的位置: 首页 > 综合 > 正文

define c/c++

2014年02月20日 ⁄ 综合 ⁄ 共 235字 ⁄ 字号 评论关闭
#define hellosun "hello"
#define B(x) #@x	//char
#define D(x) x##sun	//union
#define E(x) #x		//string
#define $ON 22		//$ can be used

int _tmain(int argc, char* argv[])
{
	//fun(1);
	int $5 = 5;
	printf("%d, %d, %c, %s\n", $ON, $5, B(h), E(hello));
	printf("%s", D(hello));
	return 0;
}

抱歉!评论已关闭.