29 Jun
2005
29 Jun
'05
4:34 p.m.
Dave Steffen
#define FOO(T) \
#define FOO do{/* here goes your macro */} while(0)
Is anyone aware of a way to silence the "extra ;" errors? (I've
semicolon is required after "while(0)", thus compiler will no complain any longer if you put whole macro inside "do{...} while(0)" block, as shown above. It's very old trick, actually ... B.