-
Notifications
You must be signed in to change notification settings - Fork 5.1k
Description
Copied from #50526, since this issue references both Serialization and Xml APIs. This copy can be used to track the Xml API.
As part of #47228 i am running an analyzer to detect APIs throwing PNSE but not annotated with Obsolete/SupportedOSPlatform/UnsupportedOSPlatform attributes, we need to annotate them so that developers get warnings when they use them unexpectedly
For now, I have results only cross-platform builds, analysis of targeted builds are coming soon where more APIs could be detected
API | Comment | Suggestion | Location |
---|---|---|---|
unconditionally throws on all platforms | add [Obsolete] | libraries\System.Private.DataContractSerialization\src\System\Runtime\Serialization\XmlObjectSerializerReadContextComplex.cs(143,13) | |
unconditionally throws on all platforms | add [Obsolete] | libraries\System.Private.DataContractSerialization\src\System\Runtime\Serialization\XsdDataContractExporter.cs(38,17) | |
unconditionally throws on all platforms | add [Obsolete] | libraries\System.Private.DataContractSerialization\src\System\Runtime\Serialization\XsdDataContractExporter.cs(59,17) | |
unconditionally throws on all platforms | add [Obsolete] | libraries\System.Private.DataContractSerialization\src\System\Xml\XmlDictionaryReader.cs(153,13) | |
unconditionally throws on all platforms | add [Obsolete] | libraries\System.Private.DataContractSerialization\src\System\Xml\XmlDictionaryReader.cs(177,13) | |
unconditionally throws on all platforms | add [Obsolete] | libraries\System.Private.DataContractSerialization\src\System\Xml\XmlDictionaryWriter.cs(68,13) | |
'XmlCollation.CreateSortKey(string)' | Unsupported on Unux (AnyOS than windows) | make XmlCollation.UpperFirst windows only | libraries\System.Private.Xml\src\System\Xml\Xsl\Runtime\XmlCollation.Unix.cs(24,17) |
Note: We are suggesting adding [Obsolete] for the APIs only supported in .Net framework but not supported in .NetCore, with the corresponding Message, DiagnosticId, and UrlFormat
runtime/src/libraries/System.Net.Requests/src/System/Net/AuthenticationManager.cs
Line 17 in cecc76a
[Obsolete(Obsoletions.AuthenticationManagerMessage, DiagnosticId = Obsoletions.AuthenticationManagerDiagId, UrlFormat = Obsoletions.SharedUrlFormat)] |