Created
February 15, 2022 20:29
-
-
Save chamons/7cb21ad92777b9dfd223eb65b8f87cc0 to your computer and use it in GitHub Desktop.
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
diff --git a/src/generator.cs b/src/generator.cs | |
index 33dc3fee2..0bf0d3cf4 100644 | |
--- a/src/generator.cs | |
+++ b/src/generator.cs | |
@@ -3367,36 +3367,7 @@ public partial class Generator : IMemberGatherer { | |
// more important since dotnet and legacy have different minimums (so this can't be done in binding files) | |
bool FilterMinimumVersion (AvailabilityBaseAttribute aa) | |
{ | |
-#if NET | |
- // dotnet can never filter minimum versions, as they are semantically important in some cases | |
- // See for details: https://github.com/xamarin/xamarin-macios/issues/10170 | |
return true; | |
-#else | |
- if (aa.AvailabilityKind != AvailabilityKind.Introduced) | |
- return true; | |
- | |
- Version min; | |
- switch (aa.Platform) { | |
- case PlatformName.iOS: | |
- min = Xamarin.SdkVersions.MiniOSVersion; | |
- break; | |
- case PlatformName.TvOS: | |
- min = Xamarin.SdkVersions.MinTVOSVersion; | |
- break; | |
- case PlatformName.WatchOS: | |
- min = Xamarin.SdkVersions.MinWatchOSVersion; | |
- break; | |
- case PlatformName.MacOSX: | |
- min = Xamarin.SdkVersions.MinOSXVersion; | |
- break; | |
- case PlatformName.MacCatalyst: | |
- min = Xamarin.SdkVersions.MinMacCatalystVersion; | |
- break; | |
- default: | |
- throw new BindingException (1047, aa.Platform.ToString ()); | |
- } | |
- return aa.Version > min; | |
-#endif | |
} | |
static AvailabilityBaseAttribute CloneFromOtherPlatform (AvailabilityBaseAttribute attr, PlatformName platform) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment