Skip to content

test/harness/parse_dg: remove C23-illegal instances of bool#105

Merged
Bodigrim merged 1 commit into
visq:masterfrom
sternenseemann:c23-harness
Mar 14, 2026
Merged

test/harness/parse_dg: remove C23-illegal instances of bool#105
Bodigrim merged 1 commit into
visq:masterfrom
sternenseemann:c23-harness

Conversation

@sternenseemann
Copy link
Copy Markdown

The test suite has been failing after #104 since language-c would reject bool occurring in places where a keyword may not (as would a C compiler/preprocessor).

gcc_dg_pre.tar.bz2 contains C preprocessor output generated with older versions of GCC using older versions of the C standard. In particular bool is used as a variable name and as a (custom) type name in some of preprocessor outputs.

Since the tarball doesn't contain the original C files the output was generated from, I resorted to haphazardly editing the outputs. I made the following modifications:

  • pr38948.i: removed typedef unsigned char bool;
  • pr37684.i: removed typedef int bool;
  • enum-mode-2.i: renamed typedef … bool; to typedef … my_bool
  • Wcxx-compat-2.i: removed int bool; declaration

The test suite has been failing after visq#104 since language-c would
reject `bool` occurring in places where a keyword may not (as would
a C compiler/preprocessor).

gcc_dg_pre.tar.bz2 contains C preprocessor output generated with
older versions of GCC using older versions of the C standard. In
particular `bool` is used as a variable name and as a (custom)
type name in some of preprocessor outputs.

Since the tarball doesn't contain the original C files the output
was generated from, I resorted to haphazardly editing the outputs.
I made the following modifications:

- pr38948.i: removed `typedef unsigned char bool;`
- pr37684.i: removed `typedef int bool;`
- enum-mode-2.i: renamed `typedef … bool;` to `typedef … my_bool`
- Wcxx-compat-2.i: removed `int bool;` declaration
@Bodigrim Bodigrim merged commit 00db59a into visq:master Mar 14, 2026
15 checks passed
@Bodigrim
Copy link
Copy Markdown
Collaborator

Thanks!

@sternenseemann sternenseemann deleted the c23-harness branch March 14, 2026 10:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants