I am using Code :: Blocks 10.05 and mingw. It seems that the compiler did not recognize the classifier of restrictions and did not return "error: expected"; ",", "or") "to" src ". Do I need to pass any compiler parameter to compile it correctly?
int inet_pton4 (const char *restrict src, unsigned char *restrict dst)
p / s: it seems mingw does not support inet_pton4, so I tried to integrate the open source version into my code.
If your compiler does not support the keyword restrict, just open that keyword (a) .
restrict
, () , , , , , .
, , ( ).
, , ( ), , " ": )
(a) , C99. , gcc, restrict, , C99, , -std=c99 (gcc docs restrict 3.0).
gcc
-std=c99
- C99, , gcc , __restrict.
__restrict
restrict C99, , @paxdiablo, restrict , :
#if __STDC_VERSION__ < 199901L #define restrict /* nothing */ #endif
, #include d (, , , restrict).
#include
C, , C99 . , __STDC_VERSION__.
__STDC_VERSION__
, MinGW, gcc, gcc --std=c99 ( @paxdiablo).
gcc --std=c99
. ( #if, , .)
#if