Skip to content

Commit 5758d72

Browse files
committed
typo
1 parent d0f8f7c commit 5758d72

File tree

1 file changed

+11
-16
lines changed

1 file changed

+11
-16
lines changed

toolchain/check/testdata/facet/access.carbon

Lines changed: 11 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -210,11 +210,14 @@ fn F(U:! I where .X = .Self) {
210210
// member lookup, but can't call methods without `self`. See the
211211
// `compound_access_through_call_with_self_param.carbon` test for the former.
212212
//
213-
// CHECK:STDERR: fail_todo_compound_access_through_call.carbon:[[@LINE+4]]:6: error: value of type `<associated entity in I>` is not callable [CallToNonCallable]
214-
// CHECK:STDERR: u.(I.G());
215-
// CHECK:STDERR: ^~~~~
213+
// CHECK:STDERR: fail_todo_compound_access_through_call.carbon:[[@LINE+7]]:3: error: cannot implicitly convert non-type value of type `U` into type implementing `I` [ConversionFailureNonTypeToFacet]
214+
// CHECK:STDERR: u.(I.G)();
215+
// CHECK:STDERR: ^~~~~~~
216+
// CHECK:STDERR: fail_todo_compound_access_through_call.carbon:[[@LINE+4]]:3: note: type `U` does not implement interface `Core.ImplicitAs(I)` [MissingImplInMemberAccessNote]
217+
// CHECK:STDERR: u.(I.G)();
218+
// CHECK:STDERR: ^~~~~~~
216219
// CHECK:STDERR:
217-
u.(I.G());
220+
u.(I.G)();
218221

219222
// This is the same as the above, since G() returns a non-type value of type
220223
// `U`.
@@ -251,25 +254,17 @@ fn F(U:! I where .X = .Self) {
251254
// `u` is a non-type value. Can call methods with `self` through compound
252255
// member lookup, but can't call methods without `self`. See the
253256
// `compound_access_through_call.carbon` test for the latter.
254-
// CHECK:STDERR: fail_todo_compound_access_through_call_with_self_param.carbon:[[@LINE+4]]:6: error: member name `G2` not found in `I` [MemberNameNotFoundInInstScope]
255-
// CHECK:STDERR: u.(I.G2());
256-
// CHECK:STDERR: ^~~~
257-
// CHECK:STDERR:
258-
u.(I.G2());
257+
u.(I.G)();
259258

260259
// This is the same as the above, since G() returns a non-type value of type
261260
// `U`.
262261
//
263262
// This works because G2 has a `self` parameter.
264-
// CHECK:STDERR: fail_todo_compound_access_through_call_with_self_param.carbon:[[@LINE+8]]:3: error: cannot access member of interface `I` in type `I where .(I.X) = .Self` that does not implement that interface [MissingImplInMemberAccess]
265-
// CHECK:STDERR: U.(I.G)().(I.G2)();
263+
// CHECK:STDERR: fail_todo_compound_access_through_call_with_self_param.carbon:[[@LINE+4]]:3: error: cannot access member of interface `I` in type `I where .(I.X) = .Self` that does not implement that interface [MissingImplInMemberAccess]
264+
// CHECK:STDERR: U.(I.G)().(I.G)();
266265
// CHECK:STDERR: ^~~~~~~
267266
// CHECK:STDERR:
268-
// CHECK:STDERR: fail_todo_compound_access_through_call_with_self_param.carbon:[[@LINE+4]]:14: error: member name `G2` not found in `I` [MemberNameNotFoundInInstScope]
269-
// CHECK:STDERR: U.(I.G)().(I.G2)();
270-
// CHECK:STDERR: ^~~~
271-
// CHECK:STDERR:
272-
U.(I.G)().(I.G2)();
267+
U.(I.G)().(I.G)();
273268
}
274269

275270
// --- fail_non_const_associated.carbon

0 commit comments

Comments
 (0)