[Diagnostics] Add inaccessible member diagnostic

This commit is contained in:
Pavel Yaskevich
2019-03-16 16:42:50 -07:00
parent 196f732cc8
commit 688042becf
13 changed files with 149 additions and 30 deletions

View File

@@ -30,7 +30,9 @@ class SimpleChildClass : SimpleClass {
// The enum should have a case for each of the vars.
// NOTE: This expected error will need to be removed in the future.
let _ = SimpleChildClass.CodingKeys.w // expected-error {{'CodingKeys' is inaccessible due to 'private' protection level}}
let _ = SimpleChildClass.CodingKeys.w
// expected-error@-1 {{'CodingKeys' is inaccessible due to 'private' protection level}}
// expected-error@-2 {{type 'SimpleClass.CodingKeys' has no member 'w'}}
// Inherited vars should not be part of the CodingKeys enum.
// NOTE: This expected error will need to be updated in the future.