-
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
Source Link support in Go To Definition #55834
Comments
@jmarolf I think you want this to be either Epic or Theme, probably Epic, right? |
I feel strangely violated |
Sorry @davidwengier I am labeling things to see what happens on themeof.net. They don't mean anything yet. Just experiementing |
Now I feel strangely violated |
Is this supposed to work even partially with |
@Meligy I'm not sure what that setting means, nor where you would set it. In general Go To Def works regardless of what repo code may come from, but the Source Link aspect would not work if there wasn't Source Link information in the PDBs of the referenced DLLs. If you're having issues with things not working, it's probably best to just log an issue and we can investigate. |
Hi @davidwengier. Thanks for the reply and sorry for not providing enough context. I was checking why Omnisharp decompilation support was not showing implementation for BCL methods (for a simply example, I understand that in Visual Studio (at least for Windows, maybe for Mac but did not check) there are settings to add symbol servers, download symbols from them, and use these for debugging and maybe decompilation. I was hoping there was something similar when consuming Roslyn via VS Code / Omnisharp. |
Unfortunately the components that enable Roslyn to download PDBs and Source Link files are part of Visual Studio, and don't ship with OmniSharp/the C# extension. |
@Meligy The documentation for configuring Symbol and Source Link options for the .NET Core Debugger in the C# extension can be found at https://github.com/OmniSharp/omnisharp-vscode/blob/master/debugger-launchjson.md#symbol-options |
@JoeRobich thanks a lot. I was actually wondering more about decompilation without debugging (think: right click a symbol and choose "Go to Definition/implementation"). But this is also very useful. I wonder if once downloaded, this become available to use even without debugging. |
@Meligy If you set |
Allow Go To Definition to pull sources from Source Link enabled assemblies.
See also #24349
Background:
Embed document information into the PDB for types that don't otherwise have itAdd documents to PDB for types that have no methods with IL #56278Process:
Given a symbol, get the metadata token for itAdd public API to retrieve metadata token from ISymbol #53486 / Add ISymbol.MetadataToken #55913ref assemblies don't have pdbs, so need a "real" oneCan tell by an attribute in the DLLref\*
then we might just need to go to..\lib\*
Given the implementation assembly, find the PDBDebugger will provide this service (exposed over service broker) that gives us the PDB given some information we find in the implementation DLL (MVID)Given the PDB and metadata token, find the source link URLSamuel worked of going from metadata token to source link url and document etc.Cherry-pick/cleanup Gtd - samuel #54337We need to download the source from the URLDebugger will provide this service, taking into account their various cachesPut the source in a workspaceMiscellaneous workspace is fine to start withPossibly fine for everything, but probably need to create a project to put things inNew compilations will have embedded options and references, so should be straight forwardPDB could be embedded. Source could be embeddedGo To Definition from source information in PDBs #57073Follow ups:[SourceLink] Ensure embedded source is shown with the right encoding #57350[SourceLink] Ensure source file found on disk matches compiled DLL #57351[SourceLink] Output window logging #57352[SourceLink] Use PEReader to try to read pdbs #57417Support Go To Implementation/Base: Go to Implementation/Base to include external references #58147Also:
The text was updated successfully, but these errors were encountered: