@@ -75,27 +75,33 @@ func testCategoryWithInitializer() {
75
75
let obj = PropertiesInitCategory ( )
76
76
77
77
let _: Int = obj. nullabilityChange
78
- // CHECK: [[@LINE-1]]:20: error: cannot convert value of type 'Base' to specified type 'Int'
78
+ // CHECK-PUBLIC: [[@LINE-1]]:20: error: cannot convert value of type 'Base' to specified type 'Int'
79
+ // CHECK-PRIVATE: [[@LINE-2]]:20: error: cannot convert value of type 'Base?' to specified type 'Int'
79
80
80
81
let _: Int = obj. missingGenerics
81
- // CHECK: [[@LINE-1]]:20: error: cannot convert value of type 'GenericClass<Base>' to specified type 'Int'
82
+ // CHECK-PUBLIC: [[@LINE-1]]:20: error: cannot convert value of type 'GenericClass<Base>' to specified type 'Int'
83
+ // CHECK-PRIVATE: [[@LINE-2]]:20: error: cannot convert value of type 'GenericClass<AnyObject>' to specified type 'Int'
82
84
83
85
let _: Int = obj. typeChange
84
- // CHECK: [[@LINE-1]]:20: error: cannot convert value of type 'Base' to specified type 'Int'
86
+ // CHECK-PUBLIC: [[@LINE-1]]:20: error: cannot convert value of type 'Base' to specified type 'Int'
87
+ // CHECK-PRIVATE: [[@LINE-2]]:20: error: cannot convert value of type 'PrivateSubclass' to specified type 'Int'
85
88
86
89
obj. readwriteChange = Base ( ) // CHECK-PRIVATE-NOT: [[@LINE]]:{{.+}}: error
87
90
// CHECK-PUBLIC: [[@LINE-1]]:7: error: cannot assign to property: 'readwriteChange' is a get-only property
88
91
}
89
92
90
93
func testCategoryWithoutInitializer( obj: PropertiesNoInitCategory ) {
91
94
let _: Int = obj. nullabilityChange
92
- // CHECK: [[@LINE-1]]:20: error: cannot convert value of type 'Base' to specified type 'Int'
95
+ // CHECK-PUBLIC: [[@LINE-1]]:20: error: cannot convert value of type 'Base' to specified type 'Int'
96
+ // CHECK-PRIVATE: [[@LINE-2]]:20: error: cannot convert value of type 'Base?' to specified type 'Int'
93
97
94
98
let _: Int = obj. missingGenerics
95
- // CHECK: [[@LINE-1]]:20: error: cannot convert value of type 'GenericClass<Base>' to specified type 'Int'
99
+ // CHECK-PUBLIC: [[@LINE-1]]:20: error: cannot convert value of type 'GenericClass<Base>' to specified type 'Int'
100
+ // CHECK-PRIVATE: [[@LINE-2]]:20: error: cannot convert value of type 'GenericClass<AnyObject>' to specified type 'Int'
96
101
97
102
let _: Int = obj. typeChange
98
- // CHECK: [[@LINE-1]]:20: error: cannot convert value of type 'Base' to specified type 'Int'
103
+ // CHECK-PUBLIC: [[@LINE-1]]:20: error: cannot convert value of type 'Base' to specified type 'Int'
104
+ // CHECK-PRIVATE: [[@LINE-2]]:20: error: cannot convert value of type 'PrivateSubclass' to specified type 'Int'
99
105
100
106
obj. readwriteChange = Base ( ) // CHECK-PRIVATE-NOT: [[@LINE]]:{{.+}}: error
101
107
// CHECK-PUBLIC: [[@LINE-1]]:7: error: cannot assign to property: 'readwriteChange' is a get-only property
0 commit comments