Build `gmsh` error with `CGNS` option `CGNS_SCOPE_ENUMS` on.
When the cgns
is built with CGNS_SCOPE_ENUMS
on, the enumerate type in cgns
will start with CG_
.
As in this case, the ElementType_t
will be CG_ElementType_t
, and this will result in error:
/Geo/CGNSConventions.h:22:1: error: 'ElementType_t' does not name a type; did you mean 'ElementType'?
Will this be fixed?
The definition of CGNS_SCOPE_ENUMS
is listed below.
#if CG_BUILD_SCOPE
# ifndef CGNS_SCOPE_ENUMS
# define CGNS_SCOPE_ENUMS
# endif
#else
# ifdef CGNS_SCOPE_ENUMS
# undef CGNS_SCOPE_ENUMS
# endif 54 #endif
#ifdef CGNS_SCOPE_ENUMS
/* set scope prefix for values only */
#define CGNS_ENUMV( e ) CG_ ## e
/* set scope prefix for types */
#define CGNS_ENUMT( e ) CG_ ## e /* /* set scope prefix for defines */
#define CGNS_ENUMD( e ) CG_ ## e
/* set scope prefix for variables (lowercase same as functions) */
#define CGNS_ENUMF( e ) cg_ ## e
#else
#define CGNS_ENUMV( e ) e
#define CGNS_ENUMT( e ) e
#define CGNS_ENUMD( e ) e
#define CGNS_ENUMF( e ) e
#endif
Edited by Zongze Yang