-
Notifications
You must be signed in to change notification settings - Fork 4k
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
Find All References does not find references to Deconstruct #18963
Comments
Cyrus gave me an overview of how Find All References works, using the parallel of The second step requires an API from the compiler, something like Besides that, there is also work to build the index. The code is in |
📝 The design for a |
Can you give examples? The ones i can think of are like so: ((int i, int j), int k) = ... In this case, i would expect to be able to get DeconstructoinInfo on In other words, even whne we have nested deconstructs, isn't there a piece of syntax we can be calling on to just see that single level of deconstruction? |
I was thinking that Your approach is to use parts of the left-hand-side as inputs instead. I like that! Then I think the result ( Two more questions:
|
@jcouv - removing IDE label until the API exists, since we can't do anything here. |
I discussed the API design with Neal. He convinced me that we should expose this through Internally, deconstructions are modeled as conversions, although they are not called that in the language. A deconstruction conversion has a Some examples to see how this approach would work:
@CyrusNajmabadi Would that work from the IDE perspective? FYI @VSadov (relates to exposing tuple conversions through public API) |
Sure. Seems like it would work fine. We could also generally extend this to make it so that goto-def on an equals sign would work for other conversions as well. i.e. if there was a user defined conversion from X to Y and you had: "Y y = x" then goto-def on the equals would take you to the conversion. |
Relates to #11803 (asking for public API to expose tuple conversions). |
Merge fix, expected to ship in 15.6 |
See code below. Notice that CodeLens shows the same (0 references).
The text was updated successfully, but these errors were encountered: