Skip to content

Conversation

@bolt12
Copy link
Collaborator

@bolt12 bolt12 commented Nov 17, 2025

This PR closes #755

  • Reorganized examples/golden/ into 11 subdirectories:
    • types/ - Type system tests (primitives, structs, unions, enums, typedefs)
    • functions/ - Function declarations, callbacks, attributes
    • arrays/ - Array tests
    • macros/ - C preprocessor macro tests
    • declarations/ - Scoping, redeclaration, linkage
    • attributes/ - GCC/Clang attributes
    • program-analysis/ - Slicing, selection, reparsing
    • documentation/ - Doxygen, pragmas
    • edge-cases/ - UTF-8, asm, special names
    • binding-specs/ - Binding specification tests
    • globals/ - Global variable tests
    • manual/ - Manual examples (already existed)

@bolt12 bolt12 self-assigned this Nov 17, 2025
* Reorganized `examples/golden/` into 11 subdirectories:
  * `types/`            - Type system tests (primitives, structs, unions, enums, typedefs)
  * `functions/`        - Function declarations, callbacks, attributes
  * `arrays/`           - Array tests
  * `macros/`           - C preprocessor macro tests
  * `declarations/`     - Scoping, redeclaration, linkage
  * `attributes/`       - GCC/Clang attributes
  * `program-analysis/` - Slicing, selection, reparsing
  * `documentation/`    - Doxygen, pragmas
  * `edge-cases/`       - UTF-8, asm, special names
  * `binding-specs/`    - Binding specification tests
  * `globals/`          - Global variable tests
  * `manual/`           - Manual examples (already existed)
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Move this to attributes.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Move this to macros folder.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In the types folder, further categorize the files: structs, enums, bool, etc..

Copy link
Collaborator

@edsko edsko left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

image

Now you're just showing off 🙄


--
-- Clang diagnostics
--

, testDiagnostic "attributes" $ \diag ->
, testDiagnostic "attributes/attributes" $ \diag ->
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Have a global test list that is sorted by test name. In order to do that, associate these tests (testDiagnostic, e.g.) to variable names and add them to a list.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

make them top level function definitions instead

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.

Reorganize golden tests

3 participants