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
// CHECK:STDERR: fail_todo_cycle_through_self_reference.carbon:[[@LINE+7]]:11: error: associated constant has incomplete type `Z` [IncompleteTypeInAssociatedConstantDecl]
371
+
// CHECK:STDERR: let U:! Z;
372
+
// CHECK:STDERR: ^
373
+
// CHECK:STDERR: fail_todo_cycle_through_self_reference.carbon:[[@LINE-7]]:1: note: interface is currently being defined [InterfaceIncompleteWithinDefinition]
// CHECK:STDERR: fail_todo_reference_same_constant_in_different_self.carbon:[[@LINE+7]]:11: error: associated constant has incomplete type `Z` [IncompleteTypeInAssociatedConstantDecl]
391
+
// CHECK:STDERR: let U:! Z;
392
+
// CHECK:STDERR: ^
393
+
// CHECK:STDERR: fail_todo_reference_same_constant_in_different_self.carbon:[[@LINE-7]]:1: note: interface is currently being defined [InterfaceIncompleteWithinDefinition]
394
+
// CHECK:STDERR: interface Z {
395
+
// CHECK:STDERR: ^~~~~~~~~~~~~
396
+
// CHECK:STDERR:
397
+
let U:! Z;
398
+
}
399
+
400
+
// TODO: Should not be diagnosed as a cycle, once the incorrect failure above is
401
+
// fixed.
402
+
fnF(A:! Z where .T= (), B:! Z where .T= .U.T and .U= A) {}
// CHECK:STDERR: fail_todo_non_cycle_with_self_reference.carbon:[[@LINE+7]]:11: error: associated constant has incomplete type `Z` [IncompleteTypeInAssociatedConstantDecl]
411
+
// CHECK:STDERR: let T:! Z;
412
+
// CHECK:STDERR: ^
413
+
// CHECK:STDERR: fail_todo_non_cycle_with_self_reference.carbon:[[@LINE-6]]:1: note: interface is currently being defined [InterfaceIncompleteWithinDefinition]
414
+
// CHECK:STDERR: interface Z {
415
+
// CHECK:STDERR: ^~~~~~~~~~~~~
416
+
// CHECK:STDERR:
417
+
let T:! Z;
418
+
let U:!type;
419
+
// TODO: This should not be an error.
420
+
//
421
+
// CHECK:STDERR: fail_todo_non_cycle_with_self_reference.carbon:[[@LINE+7]]:11: error: associated constant has incomplete type `Z` [IncompleteTypeInAssociatedConstantDecl]
422
+
// CHECK:STDERR: let V:! Z;
423
+
// CHECK:STDERR: ^
424
+
// CHECK:STDERR: fail_todo_non_cycle_with_self_reference.carbon:[[@LINE-17]]:1: note: interface is currently being defined [InterfaceIncompleteWithinDefinition]
425
+
// CHECK:STDERR: interface Z {
426
+
// CHECK:STDERR: ^~~~~~~~~~~~~
427
+
// CHECK:STDERR:
428
+
let V:! Z;
429
+
}
430
+
431
+
// TODO: Should not be diagnosed as a cycle, once the incorrect failure above is
432
+
// fixed.
433
+
fnF(A:! Z where .T= .V.U and .V= .Self and .U= ()) -> A.T {
// CHECK:STDERR: fail_todo_nested_facet_types_same_two_associated.carbon:[[@LINE+4]]:12: error: associated constant `.(Z.T)` given two different values `.(Z.V)` and `.(Z.U)` [AssociatedConstantWithDifferentValues]
58
+
// CHECK:STDERR: fn F(FF:! ((Z where .T = .U and .U = .V) where .T = .U and .U = .V) where .T = .U and .U = .V) {}
fnF(FF:! ((Z where .T= .U and .U= .V) where .T= .U and .U= .V) where .T= .U and .U= .V) {}
62
+
46
63
// --- fail_nested_facet_types_different.carbon
47
64
library "[[@TEST_NAME]]";
48
65
@@ -174,6 +191,9 @@ interface Z { let X:! type; let Y:! type; }
174
191
// Verify that the `.Y = ()` does not get applied to `.X = .Y` prematurely, as
175
192
// that would lead to `.X = () and .X = .Y` when combined with the outer `where`
176
193
// expression, which would be an error.
194
+
//
195
+
// TODO: There should be no diagnostic here.
196
+
//
177
197
// CHECK:STDERR: fail_todo_repeated_with_value_available.carbon:[[@LINE+4]]:10: error: associated constant `.(Z.X)` given two different values `()` and `.(Z.Y)` [AssociatedConstantWithDifferentValues]
178
198
// CHECK:STDERR: fn F(T:! ((Z where .Y = ()) where .X = .Y) where .X = .Y) -> T.X {
0 commit comments