Skip to content

Unresolved assembly references error when decompiling a netstandard2 dll included with .NET Framework 4.6.1 dll #2054

Description

@mmusu3

Input code

UnresolvedRefsTest.zip
Open NetStandard2Lib.dll Class1 in ILSpy

Erroneous output

ILSpy displays a warning that says some assembly references could not be resolved automatically (I can't seem to copy the text).
The decompiler does not produce the correct output in these circumstances.

private void Test(IEnumerable<string> strings)
{
	Console.Write(Enumerable.Sum<string>(strings, (Func<string, int>)((string s) => s.Length)));
}

Expected output

This is the source code for the test method.

void Test(IEnumerable<string> strings)
{
    int length = strings.Sum(s => s.Length);
    Console.Write(length);
}

Details

  • Product in use: ILSpy VS extension. I have also had the issue decompiling another whole project using the decompiler library.
  • Version in use: 6.0.0.5830-rc1
  • Other info: Does not occur when decompiling the NetStandard2Lib.dll when isolated from the other dlls.

Activity

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

Metadata

Metadata

Labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions