Cannot navigate between symbols in the same decompiled file
See original GitHub issueEnvironment data
dotnet --info
output:
.NET SDK (reflecting any global.json):
Version: 5.0.302
Commit: c005824e35
Runtime Environment: OS Name: Windows OS Version: 10.0.18363 OS Platform: Windows RID: win10-x64 Base Path: C:\Program Files\dotnet\sdk\5.0.302\
Host (useful for support): Version: 5.0.8 Commit: 35964c9215
.NET SDKs installed: 2.2.402 [C:\Program Files\dotnet\sdk] 5.0.100 [C:\Program Files\dotnet\sdk] 5.0.302 [C:\Program Files\dotnet\sdk]
.NET runtimes installed: Microsoft.AspNetCore.All 2.1.28 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.All] Microsoft.AspNetCore.All 2.2.7 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.All] Microsoft.AspNetCore.App 2.1.28 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App] Microsoft.AspNetCore.App 2.2.7 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App] Microsoft.AspNetCore.App 3.1.17 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App] Microsoft.AspNetCore.App 5.0.8 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App] Microsoft.NETCore.App 2.1.28 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App] Microsoft.NETCore.App 2.2.7 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App] Microsoft.NETCore.App 3.1.17 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App] Microsoft.NETCore.App 5.0.8 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App] Microsoft.WindowsDesktop.App 3.1.17 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App] Microsoft.WindowsDesktop.App 5.0.8 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
VS Code version: 1.60.2 C# Extension version: 1.23.16
OmniSharp log
[warn]: OmniSharp.Roslyn.CSharp.Services.Navigation.FindUsagesService
No document found. File: $metadata$\Project\QT\API\MultiOfferingWrite\WebApi\Assembly\Newtonsoft\Json\Symbol\Newtonsoft\Json\JsonConvert.cs.
Steps to reproduce
- Enable decompilation by adding the following settings into
%USERPROFILE%/.omnisharp/omnisharp.json
"RoslynExtensionsOptions": {
"enableDecompilationSupport": true
}
- Hit <kbd>F12</kbd> to decompile
JsonConvert.DeserializeObject()
in
var entitlements = JsonConvert.DeserializeObject<EntitlementClaimItem[]>(claimEntitlements.Value);
- it shows up the decompiled file
[metadata] JsonConvert.cs
which is good.
[DebuggerStepThrough]
public static T DeserializeObject<T>(string value)
{
return JsonConvert.DeserializeObject<T>(value, (JsonSerializerSettings?)null);
}
-
When clicking on
DeserializeObject
inreturn JsonConvert.DeserializeObject<T>(value, (JsonSerializerSettings?)null);
, the abovewarning
message shows up in the OmniSharp log. Hitting <kbd>F12</kbd> to further decompileDeserializeObject
inreturn JsonConvert.DeserializeObject<T>(value, (JsonSerializerSettings?)null);
results in pop up showing thatwarning
message as below -
But if clicking on
JsonSerializerSettings
inreturn JsonConvert.DeserializeObject<T>(value, (JsonSerializerSettings?)null);
, even the abovewarning
message also shows up in the OmniSharp log, but hitting <kbd>F12</kbd> to further decompileJsonSerializerSettings
actually succeeds without issues in this case.
Expected behavior
Should be able to further decompile the from the decompiled code.
Actual behavior
Looks like many objects aren’t able to be further compiled successfully from the decompiled code, while a few are able to. So the user experience isn’t good. When i use ILSpy
directly to decompile the same DLLs there’s no problem.
Issue Analytics
- State:
- Created 2 years ago
- Comments:7 (1 by maintainers)
Top GitHub Comments
Hi. Two months have passed since the issue was registered. Actually, this bug occured since 1.23.13 (Juy 13th, 2021). Any progress?
Close it as the PR has been merged😄