inline funcType funcName(...) {...}
inline 是 C++ 新增的特性。c++
#define SQUARE(X) X*X b=SQUARE(4.5+7.5); //is replaced by b=4.5+7.5*4.5+7.5; c=SQUARE(c++); //is replaced by c=c++*c++ inline int SQUARE(int a, int b) { return a*b; } b=SQUARE(4.5+7.5); //is equal to b=(4.5+7.5)*(4.5+7.5) d=SQUARE(c++); //is equal to d=c*c; c=c+1