Skip to content

ctest: fix bug where functions and statics aren't skipped #4644

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Aug 13, 2025

Conversation

mbyx
Copy link
Contributor

@mbyx mbyx commented Aug 12, 2025

Description

Fixed extern fns and extern statics not being skipped properly. Also added a rename_alias method that should be preferred to be used over rename_type.

Sources

Checklist

  • Relevant tests in libc-test/semver have been updated
  • No placeholder or unstable values like *LAST or *MAX are
    included (see #3131)
  • Tested locally (cd libc-test && cargo test --target mytarget);
    especially relevant for platforms that may not be checked in CI

@rustbot rustbot added ctest Issues relating to the ctest crate S-waiting-on-review labels Aug 12, 2025
@tgross35
Copy link
Contributor

Could you add a test case for this? Add a skip to one of the bless tests so we know if it changes in the future

@tgross35
Copy link
Contributor

Also, can rename_type just be deleted here? Assuming its functionality is now covered by the split rename_* functions

@mbyx
Copy link
Contributor Author

mbyx commented Aug 13, 2025

I don't think rename_type can be deleted. rename_alias would only work for MapInput items that are passed as MapInput::Alias, so it only affects the alias tests. But if some other test uses for example *const type_alias (or even just field: type_alias), then that is regarded as a MapInput::Type, so rename_alias wouldn't work.

Definitely something to be improved, since that part of the codebase is definitely the most buggy.

@mbyx mbyx force-pushed the ctest-next-bug-fix branch 2 times, most recently from 1bb8347 to 93e0915 Compare August 13, 2025 05:28
@mbyx mbyx mentioned this pull request Aug 13, 2025
1 task
@tgross35 tgross35 enabled auto-merge August 13, 2025 06:23
@tgross35 tgross35 added this pull request to the merge queue Aug 13, 2025
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Aug 13, 2025
@tgross35 tgross35 added this pull request to the merge queue Aug 13, 2025
Merged via the queue into rust-lang:main with commit 041ac9d Aug 13, 2025
91 of 100 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ctest Issues relating to the ctest crate
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants