> I have been reading the OpenBSD source code and have been running > across some structures||Macros i'm not understanding. Where would i > look for more explanition about the __P Macros. This is historical code... Old pre-ANSI compilers didn't support prototypes for functions. __P(X) was defined as emptiness on these platforms, therefore, function prototypes always looked like 'int function()' . On ANSI compilers, __P(X) is defined as X, so function prototypes were properly defined as 'int function(int a, double b)' . The __P macro was traditionnaly used to provide portability on both type of compilers. Best regards, -Frank.
转载于:https://www.cnblogs.com/RichardLee/archive/2012/02/28/2371621.html