Hi,

On Sat, 2008-09-13 at 11:21 -0400, Nicolas Robidoux wrote:

> Given that the restrict keyword may be defined by default for other compilers 
> than gcc (it is in gcc 
> 
> http://developer.apple.com/documentation/DeveloperTools/gcc-4.0.1/gcc/Other-Builtins.html
> 
> wouldn't the following be better?
> 
> #ifndef restrict
> #ifndef G_GNUC_RESTRICT
> #if defined (__GNUC__) && (__GNUC__ >= 4)
> #define G_GNUC_RESTRICT __restrict__
> #else
> #define G_GNUC_RESTRICT
> #endif
> #define restrict G_GNUC_RESTRICT
> #endif
> #endif

Well, using plain "restrict" probably only works if C99 is enabled. And
if C99 is enabled, then there's no need for this macro. So the easiest
solution would certainly be to switch to C99 for GEGL.


Sven


_______________________________________________
Gegl-developer mailing list
Gegl-developer@lists.XCF.Berkeley.EDU
https://lists.XCF.Berkeley.EDU/mailman/listinfo/gegl-developer

Reply via email to