1. conference编译错误,如下:
*min/max macro related.
/Developer325/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.2.sdk/usr/include/c++/4.2.1/bits/locale_facets.tcc:610:34: error: macro "min" requires 2 arguments, but only 1 given
/Developer325/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.2.sdk/usr/include/c++/4.2.1/bits/locale_facets.tcc:610:67: error: macro "max" requires 2 arguments, but only 1 given
In file included from /Developer325/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.2.sdk/usr/include/c++/4.2.1/istream:845,
from /Developer325/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.2.sdk/usr/include/c++/4.2.1/iostream:46,
root cause:
在我们的AnnotationAPI.h中,定义了min/max两个宏,将其注释后,OK!
/*
#ifndef max
#define max(a,b) (((a) > (b)) ? (a) : (b))
#endif
#ifndef min
#define min(a,b) (((a) < (b)) ? (a) : (b))
#endif
*/
* error: expected primary-expression before '{' token
源自以下statement: