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
func f6_50734<@discardableResult T>(x:T){} // expected-error {{'@discardableResult' attribute cannot be applied to this declaration}}
149
149
enumE_50734<@indirect T>{} // expected-error {{'indirect' is a declaration modifier, not an attribute}} expected-error {{'indirect' modifier cannot be applied to this declaration}}
150
150
protocol P {
151
-
@available(swift, introduced:4.2) associatedtype Assoc // expected-error {{'@available' attribute cannot be applied to this declaration}}
associatedtypeD:BetweenTargetsProto // expected-error {{'BetweenTargetsProto' is only available in macOS 10.14.5 or newer; clients of 'Test' may have a lower deployment target}}
1470
+
// expected-note@-1{{add @available attribute to enclosing associated type}}
1470
1471
associatedtypeE:AtDeploymentTargetProto // expected-error {{'AtDeploymentTargetProto' is only available in macOS 10.15 or newer; clients of 'Test' may have a lower deployment target}}
1472
+
// expected-note@-1{{add @available attribute to enclosing associated type}}
1471
1473
associatedtypeF:AfterDeploymentTargetProto // expected-error {{'AfterDeploymentTargetProto' is only available in}}
1474
+
// expected-note@-1{{add @available attribute to enclosing associated type}}
1472
1475
}
1473
1476
1474
1477
@available(macOS 10.9,*)
@@ -1477,8 +1480,11 @@ public protocol BeforeInliningTargetProtoWithAssoc {
1477
1480
associatedtypeB:BeforeInliningTargetProto
1478
1481
associatedtypeC:AtInliningTargetProto
1479
1482
associatedtypeD:BetweenTargetsProto // expected-error {{'BetweenTargetsProto' is only available in macOS 10.14.5 or newer; clients of 'Test' may have a lower deployment target}}
1483
+
// expected-note@-1{{add @available attribute to enclosing associated type}}
1480
1484
associatedtypeE:AtDeploymentTargetProto // expected-error {{'AtDeploymentTargetProto' is only available in macOS 10.15 or newer; clients of 'Test' may have a lower deployment target}}
1485
+
// expected-note@-1{{add @available attribute to enclosing associated type}}
1481
1486
associatedtypeF:AfterDeploymentTargetProto // expected-error {{'AfterDeploymentTargetProto' is only available in}}
1487
+
// expected-note@-1{{add @available attribute to enclosing associated type}}
1482
1488
}
1483
1489
1484
1490
@available(macOS 10.10,*)
@@ -1487,8 +1493,11 @@ public protocol AtInliningTargetProtoWithAssoc {
1487
1493
associatedtypeB:BeforeInliningTargetProto
1488
1494
associatedtypeC:AtInliningTargetProto
1489
1495
associatedtypeD:BetweenTargetsProto // expected-error {{'BetweenTargetsProto' is only available in macOS 10.14.5 or newer; clients of 'Test' may have a lower deployment target}}
1496
+
// expected-note@-1{{add @available attribute to enclosing associated type}}
1490
1497
associatedtypeE:AtDeploymentTargetProto // expected-error {{'AtDeploymentTargetProto' is only available in macOS 10.15 or newer; clients of 'Test' may have a lower deployment target}}
1498
+
// expected-note@-1{{add @available attribute to enclosing associated type}}
1491
1499
associatedtypeF:AfterDeploymentTargetProto // expected-error {{'AfterDeploymentTargetProto' is only available in}}
1500
+
// expected-note@-1{{add @available attribute to enclosing associated type}}
1492
1501
}
1493
1502
1494
1503
@available(macOS 10.14.5,*)
@@ -1498,7 +1507,9 @@ public protocol BetweenTargetsProtoWithAssoc {
1498
1507
associatedtypeC:AtInliningTargetProto
1499
1508
associatedtypeD:BetweenTargetsProto
1500
1509
associatedtypeE:AtDeploymentTargetProto // expected-error {{'AtDeploymentTargetProto' is only available in macOS 10.15 or newer; clients of 'Test' may have a lower deployment target}}
1510
+
// expected-note@-1{{add @available attribute to enclosing associated type}}
1501
1511
associatedtypeF:AfterDeploymentTargetProto // expected-error {{'AfterDeploymentTargetProto' is only available in}}
1512
+
// expected-note@-1{{add @available attribute to enclosing associated type}}
1502
1513
}
1503
1514
1504
1515
@available(macOS 10.15,*)
@@ -1509,6 +1520,7 @@ public protocol AtDeploymentTargetProtoWithAssoc {
1509
1520
associatedtypeD:BetweenTargetsProto
1510
1521
associatedtypeE:AtDeploymentTargetProto
1511
1522
associatedtypeF:AfterDeploymentTargetProto // expected-error {{'AfterDeploymentTargetProto' is only available in}}
1523
+
// expected-note@-1{{add @available attribute to enclosing associated type}}
1512
1524
}
1513
1525
1514
1526
@available(macOS 11,*)
@@ -1529,6 +1541,7 @@ public protocol UnavailableProtoWithAssoc {
1529
1541
associatedtypeD:BetweenTargetsProto
1530
1542
associatedtypeE:AtDeploymentTargetProto
1531
1543
associatedtypeF:AfterDeploymentTargetProto // expected-error {{'AfterDeploymentTargetProto' is only available in}}
1544
+
// expected-note@-1{{add @available attribute to enclosing associated type}}
0 commit comments