Bruno Haible <[EMAIL PROTECTED]> writes: > /* Define to equivalent of C99 restrict keyword, or to nothing if this > is not supported. Do not define if restrict is supported directly. */ > #ifdef __cplusplus > #define restrict > #else > #define restrict _Restrict > #endif
That sounds a bit pessimistic, since the semantics of "restrict" is available in some C++ compilers. We shouldn't penalize these compilers merely because Sun's C++ compiler disagrees with its C compiler. Would it suffice to append this to config.h? I don't have easy access to Sun C 5.0 any more (it's pretty old). /* Work around a bug in Sun C++: it does not support _Restrict, even though the corresponding Sun C compiler does. Perhaps some future version of Sun C++ will work with _Restrict; if so, it'll probably define __RESTRICT, just as Sun C does. */ #if defined __SUNPRO_CC && !defined __RESTRICT # define _Restrict #endif