Comments
7 comments
-
That's strange, thanks for the bug report! Can I just ask, is this for all methods (e.g. does it work for System.Console.Write("");?), or just for a particular assembly?
Also, do you have resharper installed?
Many Thanks -
Hi Jason,
Looks like it works if I invoke it on my source code but it doesn't when invoked on decompiled code.
And no, I don't have Resharper but I do have CodeRush. I doesn't matter if I unload it. -
Unfortunately the 'Go to decompiled definition' from decompiled code does not work. This is due to a technical limitation - decompiled code has the same status as a code file opened in Visual Studio which is not associated with a project (e.g. as if you opened a .cs file from explorer). Visual Studio doesn't even try to parse the code, hence we cannot identify the item we need to go to.
Sorry for this, we'll try to make this limitation more obvious in future versions. -
I kind of thought that this was the case. Perhaps you could disable or even hide the context menu option in such case?
-
OTOH since you've decompiled the code you know the file, right? I mean you could use cursor position and Reflector knowledge to understand where user is pointing and since Reflector created that file it might understand the location...
-
Nice idea. However, I suspect we wouldn't be able to do it. We would have to either parse the code and guess what things mean, which would be very fragile; or store metadata about every word in the decompiled code during decompilation (which I believe is what you were suggesting), which would be v expensive it terms of time and memory, and v hard.
I'll ask Alex Davies, the developer of this feature, about this issue. -
I hope that in a future version we'll be able to investigate the expensive storing the meaning of every word in the decompiled source, but we don't have time in this version I'm afraid.
We should be able to hide the context menu item in this situation though.
Add comment
Please sign in to leave a comment.
Go to Decompiled Definition does nothing - nothing happens. If I step in while debugging the method shows up fine.