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

Support go to let, let!, subject, and subject! definitions #38

Merged
merged 1 commit into from
Oct 6, 2024

Conversation

st0012
Copy link
Owner

@st0012 st0012 commented Sep 27, 2024

Screen.Recording.2024-09-27.at.15.05.26.mov

This is a naive implementation that lists all definitions from the same file.

To better implement this, we need to create the RSpec::ExampleGroups class structures, add the declarations as its methods, and look up the definition based on the example's context.

@st0012 st0012 added the enhancement New feature or request label Sep 27, 2024
@st0012
Copy link
Owner Author

st0012 commented Oct 6, 2024

Actually, it's not possible to support the right way atm because Ruby LSP's index enhancement doesn't support on_call_node_enter|leave events. This means that it's not possible to track when a scope is entered/left, which we need to create the correct pseudo classes.

@st0012 st0012 merged commit 97e72d3 into main Oct 6, 2024
3 checks passed
@st0012 st0012 deleted the go-to-definition branch October 6, 2024 21:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant