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
{{ message }}
Repository navigation
ILLink rooting assemblies with forwarded types #99592
area-Tools-ILLink.NET linker development as well as trimming analyzersdisabled-testThe test is disabled in source code against the issueos-iosApple iOS
The product behavior is by design here - I think the test case in question just needs special consideration if running as "Trimmed" - or maybe we should just disable it. The things it's doing are specifically against what trimming/AOT supports, so not supporting this test case in that setup seems OK to me.
I had problem with this behavior in production so maybe there should be some additional consideration on how to handle this. My scenario involved System.Windows.Forms / System.Drawing and the type forwarders there. There are serialized resources that depend on the forwarders being kept after trimming (eg. resource references System.Windows.Forms.Padding and the real type is System.Windows.Forms.Primitives.Padding). I realize that this is currently an unsupported scenario, but I still think that some consideration should be given to it and how to handle it (eg. optional switch to keep the type forwarders in specific assembly).
I think the test case in question just needs special consideration if running as "Trimmed" - or maybe we should just disable it.
We can skip the test if trimming is enabled.
My scenario involved System.Windows.Forms / System.Drawing and the type forwarders there. There are serialized resources that depend on the forwarders being kept after trimming (eg. resource references System.Windows.Forms.Padding and the real type is System.Windows.Forms.Primitives.Padding). I realize that this is currently an unsupported scenario, but I still think that some consideration should be given to it and how to handle it (eg. optional switch to keep the type forwarders in specific assembly).
I agree that adding an ILLInk warning message or an optional switch could be beneficial. Currently, it may be unclear to customers what has happened and how to resolve the issue.
area-Tools-ILLink.NET linker development as well as trimming analyzersdisabled-testThe test is disabled in source code against the issueos-iosApple iOS
Activity
vitek-karas commentedon Mar 12, 2024
The product behavior is by design here - I think the test case in question just needs special consideration if running as "Trimmed" - or maybe we should just disable it. The things it's doing are specifically against what trimming/AOT supports, so not supporting this test case in that setup seems OK to me.
filipnavara commentedon Mar 12, 2024
I had problem with this behavior in production so maybe there should be some additional consideration on how to handle this. My scenario involved System.Windows.Forms / System.Drawing and the type forwarders there. There are serialized resources that depend on the forwarders being kept after trimming (eg. resource references
System.Windows.Forms.Paddingand the real type isSystem.Windows.Forms.Primitives.Padding). I realize that this is currently an unsupported scenario, but I still think that some consideration should be given to it and how to handle it (eg. optional switch to keep the type forwarders in specific assembly).kotlarmilos commentedon Mar 12, 2024
We can skip the test if trimming is enabled.
I agree that adding an ILLInk warning message or an optional switch could be beneficial. Currently, it may be unclear to customers what has happened and how to resolve the issue.