-
I've been preparing NPOI, an xls(x) read-and-write library heavily relying on XML (de)serialization, for NativeAOT.
|
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 2 replies
-
rd.xml is not intended to be used by libraries. Instead, annotate your libraries with DynamicallyAccessedMembersAttribute, etc. |
Beta Was this translation helpful? Give feedback.
-
Some libraries are not going to be fully compatible with native AOT. It is likely the case of System.Xml.Serialization. |
Beta Was this translation helpful? Give feedback.
-
What I did was write a custom source generator that parses the xml. Worked for my case. |
Beta Was this translation helpful? Give feedback.
Annotating the library and getting to zero trim and AOT warnings is the only fully reliable way to make libraries work well with trimming and AOT.
It is not possible to find all trimming and AOT issues using unit test.