I work with primitive C Parser, which does not handle the preprocessor directive.
I can pre-process most of the header with the -E switch without any problems.
Recently, I have discovered cases where attributes are present and align .
I tried to get rid of them using this setting:
gcc -D "aligned(ARGS)" \ -D "__align__(ARGS)" \ -D "__attribute__(ARGS)" \ -E /usr/local/include/fancyheader.h
Update:
But without success, for example:
struct __attribute__((aligned(16))) long4 { long int x, y, z, w; };
The above statements translate to "1" pending
struct 1 long4 { long int x, y, z, w; };
Who knows the right way to get rid of the __align__ and __attribute__ extensions?
source share