runtime: NETStandard2.0 libraries referencing types absorbed into NETStandard2.1 cannot be used in NS2.1

How to reproduce

In Visual Studio 2019 RTM, create a new .NET Standard library, and set the target framework to “.NET Standard 2.1”. Then add a reference to System.IO.Pipelines (either the lastest stable version 4.5.3 or beta version 4.6.0-preview3-191128.7).

Error message

The type System.ReadOnlySpan<T> (or other types defined in System.Memory assembly) is defined in both System.Memory, version=4.0.1.0 and netstandard, version=2.1.0.0.

Comments

Maybe the reference list of System.IO.Pipelines assembly under netstd 2.1 should be updated in order to fix this problem, and many thanks~

About this issue

  • Original URL
  • State: closed
  • Created 5 years ago
  • Comments: 21 (18 by maintainers)

Commits related to this issue

Most upvoted comments

The change in Standard has already been absorbed by core-sdk, with dotnet/core-sdk@ebd193f#diff-5c6a1c77fe216efcfbbdccb11b863063. I believe you should be able to try validation now.

Works good ty!

Re-opening until https://github.com/dotnet/corefx/pull/37532 is done. If I am mistaken, @wtgodbe, please feel free to re-close 😃