- static const char *common_flags = NULL;
-
- if (common_flags == NULL) {
- obstack_1grow(&cppflags_obst, '\0');
- const char *flags = obstack_finish(&cppflags_obst);
-
- /* setup default defines */
- add_flag(&cppflags_obst, "-U__WCHAR_TYPE__");
- add_flag(&cppflags_obst, "-D__WCHAR_TYPE__=%s", type_to_string(type_wchar_t));
- add_flag(&cppflags_obst, "-U__SIZE_TYPE__");
- add_flag(&cppflags_obst, "-D__SIZE_TYPE__=%s", type_to_string(type_size_t));
-
- add_flag(&cppflags_obst, "-U__VERSION__");
- add_flag(&cppflags_obst, "-D__VERSION__=\"%s\"", cparser_REVISION);
-
- if (define_intmax_types) {
- add_flag(&cppflags_obst, "-U__INTMAX_TYPE__");
- add_flag(&cppflags_obst, "-D__INTMAX_TYPE__=%s", type_to_string(type_intmax_t));
- add_flag(&cppflags_obst, "-U__UINTMAX_TYPE__");
- add_flag(&cppflags_obst, "-D__UINTMAX_TYPE__=%s", type_to_string(type_uintmax_t));
- }
-
- if (flags[0] != '\0') {
- size_t len = strlen(flags);
- obstack_1grow(&cppflags_obst, ' ');
- obstack_grow(&cppflags_obst, flags, len);
- }
- obstack_1grow(&cppflags_obst, '\0');
- common_flags = obstack_finish(&cppflags_obst);
- }
-
- assert(obstack_object_size(&cppflags_obst) == 0);