forked from xamarin/xamarin-macios
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[dotnet][generator] Fix creating 3rd party bindings
Internally the generator uses `AvailabilityBaseAttribute` to make its decisions. For `dotnet` we generated the newer `[SupportedOSPlatform]` and `[UnsupportedOSPlatform]`. A 3rd-party (dotnet) binding might refer to members decorated with the newer attributes and fail the build with an error [1]. Avoiding the error is easy (first block of the diff) but it does not make the _right_ decisions (e.g. if a member is unavailable for the platform) when generating the code. To fix this we need to be able to convert the new attributes into the well know `AvailabilityBaseAttribute` subclasses. We have not spotted such cases yet because * the bindings pass our tests (good but extra code would not fail) * API diff across legacy and dotnet is not yet done [2] [1] xamarin#11497 [2] xamarin#10210
- Loading branch information
Showing
1 changed file
with
62 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters