Commit e83418d
committed
chore: ignore IL2026 in BindableMetadata.g.cs
Context: 559b1f7
Commit 559b1f7 updated `BindableMetadata.g.cs` to ignore IL2111,
because `typeof(Type)` in the binding code was emitting it.
Turns out, `typeof(Excpetion)` emits a similar IL2026!
Error: …/RecommendedMarkup/RecommendedMarkup/obj/Debug/net10.0-browserwasm/Uno.UI.SourceGenerators/Uno.UI.SourceGenerators.BindableTypeProviders.BindableTypeProvidersSourceGenerator/BindableMetadata.g.cs(1086,4): error IL2026:
Using member 'System.Exception.TargetSite.get' which has 'RequiresUnreferencedCodeAttribute' can break functionality when trimming application code. Metadata for the method might be incomplete or removed.
which is flagged on this line of code:
bindableType.AddProperty("Error", typeof(global::System.Exception), GetError);
This was encountered from uno.templates CI when building the output of:
dotnet new unoapp -n RecommendedMarkupDsp -skip -preset recommended -markup csharp -dsp
Update `BindableTypeProvidersGenerationTask` so that IL2026 is ignored.1 parent 00cf31c commit e83418d
File tree
1 file changed
+1
-0
lines changed- src/SourceGenerators/Uno.UI.SourceGenerators/BindableTypeProviders
1 file changed
+1
-0
lines changedLines changed: 1 addition & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
302 | 302 | | |
303 | 303 | | |
304 | 304 | | |
| 305 | + | |
305 | 306 | | |
306 | 307 | | |
307 | 308 | | |
| |||
0 commit comments