You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
After updating vscode started showing multiple definitions #51489
After updating from version 1.23.1 to 1.24.0 the shortcut "Go to definition" started finding two definitions where there is only one. A simple way yo reproduce is this:
constf=x=>console.log(x)f()
When I Ctrl + Click or F12 the f function it finds two definitions:
Is there any way to revert to the previews behavior?
I am using vscode v1.24.0 in Ubuntu 16.04
Thanks in advance
Reacted by Geir Sagberg, Alex J Burke, Guilherme Alan Ritter, Steve Bertan, Hamburg96, Fov, ilya.kuznetsov, Ben Foster, jldillman, Cosimo Chellini and 3 more
I noticed this as well. This seems to me to be a bug; there is only one real definition here, as is evidenced by clicking results showing the same line.
Thanks for opening this issue, I thought I was going nuts - I think what I'm experiencing is related: it looks like vscode gets confused between the call-site of a function expression and the definition of it earlier in the file, so while it jumps up to the definition it also opens up the multiple definitions pane. The effect is that every other cmd-click needs to be followed by pressing escape. Just confirmed on second machine this came in on upgrade for 1.23.1 -> 1.24.0. Thanks.
Activity
geirsagberg commentedon Jun 9, 2018
I noticed this as well. This seems to me to be a bug; there is only one real definition here, as is evidenced by clicking results showing the same line.
alexjeffburke commentedon Jun 9, 2018
Thanks for opening this issue, I thought I was going nuts - I think what I'm experiencing is related: it looks like vscode gets confused between the call-site of a function expression and the definition of it earlier in the file, so while it jumps up to the definition it also opens up the multiple definitions pane. The effect is that every other cmd-click needs to be followed by pressing escape. Just confirmed on second machine this came in on upgrade for 1.23.1 -> 1.24.0. Thanks.
mjbvz commentedon Jun 11, 2018
Thanks. Opened microsoft/TypeScript#24861 to track this upstream
benevbright commentedon Jul 7, 2018
any workaround?