Conflicting enum
and #define
identifiers make a translated header cause invalid redefinition of constant
#467
Labels
enum
and #define
identifiers make a translated header cause invalid redefinition of constant
#467
NgSpice has a habit of establishing most enum-like constants with
#define
: https://github.com/imr/ngspice/blob/902a62d2f442a1d8322ae4fcad35c143c7a14561/src/include/ngspice/noisedef.h#L72-L74but then occasionally introducing an
enum { ... }
with the same names wrapped in an ifdef guard: https://github.com/imr/ngspice/blob/902a62d2f442a1d8322ae4fcad35c143c7a14561/src/include/ngspice/acdefs.h#L29-L35Example:
result:
It would be nice if Clang.jl either:
#define
across header files so that the duplicate enum definition is not parsed, OR#define
constants, since their definitions are compatible up to a difference of integer typeThe text was updated successfully, but these errors were encountered: