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 singleton class nesting when inside top level reference #2471

Merged
merged 1 commit into from
Aug 20, 2024

Conversation

vinistock
Copy link
Member

Motivation

Fixes the bug reported in #2287 (comment)

We need to use our proper nesting resolution actual_nesting to discover the correct place where we discovered a singleton class, just like we're doing for regular classes. Otherwise, we incorrectly insert a name prefixed with :: in the index state, which we do not want.

Implementation

Started using our actual_nesting method to figure out the right nesting.

Automated Tests

Added a test.

@vinistock vinistock added bugfix This PR will fix an existing bug server This pull request should be included in the server gem's release notes labels Aug 20, 2024
@vinistock vinistock self-assigned this Aug 20, 2024
@vinistock vinistock requested a review from a team as a code owner August 20, 2024 20:15
@zachahn-gusto
Copy link

Thank you so much for the quick turnaround!!!

@vinistock vinistock enabled auto-merge (squash) August 20, 2024 20:27
@vinistock vinistock merged commit bec458c into main Aug 20, 2024
37 checks passed
@vinistock vinistock deleted the vs-fix-singleton-inside-top-level-ref branch August 20, 2024 20:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bugfix This PR will fix an existing bug server This pull request should be included in the server gem's release notes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants