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
Copy file name to clipboardExpand all lines: test/Sema/availability_versions.swift
+3-6Lines changed: 3 additions & 6 deletions
Original file line number
Diff line number
Diff line change
@@ -309,7 +309,6 @@ class SubOfClassWithUnavailableInitializer : SuperWithWithUnavailableInitializer
309
309
classClassWithUnavailableProperties{
310
310
// expected-note@-1 4{{add @available attribute to enclosing class}}
311
311
312
-
@available(OSX, introduced:10.9) // expected-error {{stored properties cannot be marked potentially unavailable with '@available'}}
313
312
varnonLazyAvailableOn10_9Stored:Int=9
314
313
315
314
@available(OSX, introduced:10.51) // expected-error {{stored properties cannot be marked potentially unavailable with '@available'}}
@@ -538,17 +537,17 @@ enum CompassPoint {
538
537
539
538
case WithAvailableByEnumPayload(p :EnumIntroducedOn10_51)
540
539
540
+
// expected-error@+1 {{enum cases with associated values cannot be marked potentially unavailable with '@available'}}
541
541
@available(OSX, introduced:10.52)
542
542
case WithAvailableByEnumElementPayload(p :EnumIntroducedOn10_52)
543
543
544
+
// expected-error@+1 2{{enum cases with associated values cannot be marked potentially unavailable with '@available'}}
544
545
@available(OSX, introduced:10.52)
545
546
case WithAvailableByEnumElementPayload1(p :EnumIntroducedOn10_52), WithAvailableByEnumElementPayload2(p :EnumIntroducedOn10_52)
546
547
547
548
case WithUnavailablePayload(p :EnumIntroducedOn10_52) // expected-error {{'EnumIntroducedOn10_52' is only available in macOS 10.52 or newer}}
548
-
// expected-note@-1 {{add @available attribute to enclosing case}}
549
549
550
-
case WithUnavailablePayload1(p :EnumIntroducedOn10_52), WithUnavailablePayload2(p :EnumIntroducedOn10_52) // expected-error 2{{'EnumIntroducedOn10_52' is only available in macOS 10.52 or newer}}
551
-
// expected-note@-1 2{{add @available attribute to enclosing case}}
550
+
case WithUnavailablePayload1(p :EnumIntroducedOn10_52), WithUnavailablePayload2(p :EnumIntroducedOn10_52) // expected-error 2{{'EnumIntroducedOn10_52' is only available in macOS 10.52 or newer}}
0 commit comments