Skip to content
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

Fix module visibility check #6685

Merged
merged 12 commits into from
Nov 15, 2024
Merged

Conversation

jjcnn
Copy link
Contributor

@jjcnn jjcnn commented Nov 1, 2024

Description

Fixes #6673.

The module visibility check has been broken for some time.

In some cases, like the one described in #6673, this has resulted in modules being mistakenly regarded as inaccessible, even though they ought to be accessible.

In other cases, private modules were mistakenly regarded as accessible. For examples see the updated tests in the PR.

The check has now been fixed, and all tests have been updated accordingly.

This bugfix can be regarded as a breaking change, because some modules that were deemed accessible before may now be deemed inaccessible and will require the addition of a pub keyword in front of the module declaration.

Checklist

  • I have linked to any relevant issues.
  • I have commented my code, particularly in hard-to-understand areas.
  • I have updated the documentation where relevant (API docs, the reference, and the Sway book).
  • I have added tests that prove my fix is effective or that my feature works.
  • I have added (or requested a maintainer to add) the necessary Breaking* or New Feature labels where relevant.
  • I have done my best to ensure that my PR adheres to the Fuel Labs Code Review Standards.
  • I have requested a review from the relevant team or maintainers.

@jjcnn jjcnn added the breaking May cause existing user code to break. Requires a minor or major release. label Nov 1, 2024
@jjcnn jjcnn self-assigned this Nov 1, 2024
@jjcnn jjcnn requested a review from a team as a code owner November 1, 2024 13:43
Copy link

codspeed-hq bot commented Nov 1, 2024

CodSpeed Performance Report

Merging #6685 will not alter performance

Comparing jjcnn/fix_module_visibility_in_tests (91d3a78) with master (3b07f49)

Summary

✅ 22 untouched benchmarks

@jjcnn jjcnn requested a review from a team as a code owner November 1, 2024 14:04
tritao
tritao previously approved these changes Nov 1, 2024
@tritao tritao requested a review from a team November 1, 2024 21:26
tritao
tritao previously approved these changes Nov 4, 2024
@IGI-111 IGI-111 removed the breaking May cause existing user code to break. Requires a minor or major release. label Nov 15, 2024
@IGI-111 IGI-111 merged commit 2b6fd7a into master Nov 15, 2024
41 checks passed
@IGI-111 IGI-111 deleted the jjcnn/fix_module_visibility_in_tests branch November 15, 2024 04:59
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.

Visibility check for modules is broken
5 participants