You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I fully support the idea of a linker in .NET Core but please consolidate the linker directives. There's rd.xml for .NET Native and this new thing. Please pick one and use it for both toolchains. Otherwise we'll need to duplicate linker directives and that's going to lead to errors.
The text was updated successfully, but these errors were encountered:
Please strongly consider to consolidate the formats.
Just hit a project where a set of .NET Standard libraries were both used in Xamarin and UWP hosts. UWP was a breathe thanks to RD.XML and its ability to be embedded right in the library.
Xamarin experience was considerably worse as I had to specify the same rules, but this time at the central location which is a linker description file. Did not like it at all, especially given the fact that some .NET Standard libraries are authored by another teams and its their responsibility to make them linker friendly, not mine.
RD.XML file format support in .NET Linker is highly welcome. This would eliminate the sharp edges and unpleasant dichotomy we currently have. Especially given the fact that .NET Linker now targets .NET Core.
The plan is to teach NativeAOT about the linker format - it actually already does some of this, main part of the missing work is tracked here: dotnet/runtime#73083
Going forward the recommendation for libraries/apps is to not use the XML files but instead use code. So either (in recommendation priority order):
direct references
use source generators to produce direct references
annotated reflection code with DynamicallyAccessedMembersAttribute
use DynamicDependencyAttribute (this is basically a code replacement for the descriptor XML file)
I fully support the idea of a linker in .NET Core but please consolidate the linker directives. There's rd.xml for .NET Native and this new thing. Please pick one and use it for both toolchains. Otherwise we'll need to duplicate linker directives and that's going to lead to errors.
The text was updated successfully, but these errors were encountered: