Skip to content

Fix System.PlatformNotSupportedException when StandardResolver is initialized. - #705

Closed
kpto wants to merge 1 commit into
MessagePack-CSharp:masterfrom
kpto:net-standard20-symbol-misspell-fix
Closed

kpto wants to merge 1 commit into
MessagePack-CSharp:masterfrom
kpto:net-standard20-symbol-misspell-fix

Conversation

@kpto

@kpto kpto commented Dec 6, 2019

Copy link
Copy Markdown

Bug description
Dynamic resolvers are not excluded from the StandardResolver when targeting .NetStandard2.0 because of the misspell of the framework symbol. System.PlatformNotSupportedException is thrown when StandardResolver is initialized.

Repro steps
var resolver = Resolvers.StandardResolver.Instance;

Expected behavior
No exception thrown.

Actual behavior
System.PlatformNotSupportedException was thrown.

Remarks
According to the doc, the spelling should be NETSTANDARD2_0
https://docs.microsoft.com/en-us/dotnet/csharp/language-reference/preprocessor-directives/preprocessor-if

Fix #701

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

How to create a blank MessagePackSerializerOptions instance without standard resolver?

1 participant