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

Go To Definition should use source link or embedded source (pdb) instead of metadata-as-source when available #2207

Closed
dmccaffery opened this issue Apr 21, 2018 · 7 comments

Comments

@dmccaffery
Copy link

dmccaffery commented Apr 21, 2018

Environment data

`dotnet --info` output:

.NET Core SDK (reflecting any global.json):
 Version:   2.1.300-preview2-008533
 Commit:    996eb6c92c

Runtime Environment:
 OS Name:     Mac OS X
 OS Version:  10.13
 OS Platform: Darwin
 RID:         osx.10.13-x64
 Base Path:   /Users/deavon/.dotnet/sdk/2.1.300-preview2-008533/

Host (useful for support):
  Version: 2.1.0-preview2-26406-04
  Commit:  6833f3026b

.NET Core SDKs installed:
  1.1.5 [/Users/deavon/.dotnet/sdk]
  1.1.7 [/Users/deavon/.dotnet/sdk]
  1.1.8 [/Users/deavon/.dotnet/sdk]
  2.1.4 [/Users/deavon/.dotnet/sdk]
  2.1.101 [/Users/deavon/.dotnet/sdk]
  2.1.105 [/Users/deavon/.dotnet/sdk]
  2.1.300-preview2-008533 [/Users/deavon/.dotnet/sdk]

.NET Core runtimes installed:
  Microsoft.AspNetCore.All 2.1.0-preview2-final [/Users/deavon/.dotnet/shared/Microsoft.AspNetCore.All]
  Microsoft.AspNetCore.App 2.1.0-preview2-final [/Users/deavon/.dotnet/shared/Microsoft.AspNetCore.App]
  Microsoft.NETCore.App 1.0.8 [/Users/deavon/.dotnet/shared/Microsoft.NETCore.App]
  Microsoft.NETCore.App 1.0.9 [/Users/deavon/.dotnet/shared/Microsoft.NETCore.App]
  Microsoft.NETCore.App 1.0.10 [/Users/deavon/.dotnet/shared/Microsoft.NETCore.App]
  Microsoft.NETCore.App 1.1.5 [/Users/deavon/.dotnet/shared/Microsoft.NETCore.App]
  Microsoft.NETCore.App 1.1.6 [/Users/deavon/.dotnet/shared/Microsoft.NETCore.App]
  Microsoft.NETCore.App 1.1.7 [/Users/deavon/.dotnet/shared/Microsoft.NETCore.App]
  Microsoft.NETCore.App 2.0.5 [/Users/deavon/.dotnet/shared/Microsoft.NETCore.App]
  Microsoft.NETCore.App 2.0.6 [/Users/deavon/.dotnet/shared/Microsoft.NETCore.App]
  Microsoft.NETCore.App 2.0.7 [/Users/deavon/.dotnet/shared/Microsoft.NETCore.App]
  Microsoft.NETCore.App 2.1.0-preview2-26406-04 [/Users/deavon/.dotnet/shared/Microsoft.NETCore.App]

To install additional .NET Core runtimes or SDKs:
  https://aka.ms/dotnet-download

VS Code version:

Version 1.22.2 (1.22.2)

C# Extension version:

1.15.0-beta4

Steps to reproduce

Use "Go To Definition" from command-pallete, context menu, keyboard shortcut, or CMD/CTRL+CLICK on a symbol contained within a package reference that contains portable-pdb embedded source or sourcelink metadata (unauthenticated).

Expected behavior

Referenced source is rendered 👍

Actual behavior

Metadata-as-code is rendered 👎

I used dotnet-sourcelink to verify that the sourcelink urls are available as well as to test a nupkg containing a portable pdb with embedded source.

@TheRealPiotrP
Copy link

@rchande

@DustinCampbell
Copy link
Member

FWIW, we'll want this in Visual Studio as well and there might be some movement on making that work at some point (VS has go to disassembly now too!). I think the best way to go about this would be to implement the feature in Roslyn, expose a properly Go to Definition API and make OmniSharp use it.

@jinujoseph: Are we tracking Source Link or embedded PDB sources for Go to Definition in Roslyn somewhere?

@rchande
Copy link

rchande commented Apr 24, 2018

Closing in favor of dotnet/roslyn#26366

@rchande rchande closed this as completed Apr 24, 2018
@jinujoseph
Copy link

yes actually here dotnet/roslyn#24349

@DustinCampbell
Copy link
Member

Thanks!

@athinboy
Copy link

Half of year has gone. Hoping for this feature!

@geekox86
Copy link

geekox86 commented Jan 7, 2020

Greetings gentlemen and thank you for the wonderful extension.
Any updates on this feature request?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

7 participants