From 8256f891440b7f135c950f9a6ca8a2f91f7771cd Mon Sep 17 00:00:00 2001 From: danakj Date: Thu, 28 Nov 2024 16:23:17 -0500 Subject: [PATCH] Remove Parse::Node, add ElementIndex in docs for typed insts The documentation still referred to typed instructions having a Parse::Node field, however that was removed and moved to the InstStore in f197219c107644. Then GetParseNode() was renamed to GetNodeId() in 86a7c9ff451f4cf and then GetLocationId() in b079acd86f00e593 and finally GetLocId() in b5d28f2c4b0fee46. The comment in typed_inst.h mentions only three fields now, but some types still have four, thanks to the unmentioned `ElementIndex index` field. Normally this field comes last, after the `[...]Id` fields except for in one case, AssociatedEntity. Rather than write ambiguously ordered documentation, update the comment to and docs to say that the ElementIndex comes last, and move it to the last position in AssociatedEntity. Tests are rebased accordingly. --- toolchain/check/import_ref.cpp | 4 +- toolchain/check/interface.cpp | 2 +- .../testdata/class/generic/import.carbon | 34 ++++++------ .../testdata/function/builtin/method.carbon | 4 +- .../no_prelude/call_from_operator.carbon | 42 +++++++-------- toolchain/check/testdata/impl/compound.carbon | 8 +-- .../check/testdata/impl/extend_impl.carbon | 4 +- .../testdata/impl/extend_impl_generic.carbon | 16 +++--- .../testdata/impl/fail_call_invalid.carbon | 4 +- .../impl/fail_extend_impl_forall.carbon | 6 +-- .../testdata/impl/fail_impl_as_scope.carbon | 4 +- .../impl/fail_impl_bad_assoc_const.carbon | 4 +- .../impl/fail_impl_bad_assoc_fn.carbon | 12 ++--- .../impl/fail_self_type_mismatch.carbon | 4 +- .../impl/fail_todo_impl_assoc_const.carbon | 4 +- toolchain/check/testdata/impl/impl_as.carbon | 4 +- .../check/testdata/impl/impl_forall.carbon | 4 +- .../check/testdata/impl/lookup/alias.carbon | 4 +- .../lookup/fail_alias_impl_not_found.carbon | 4 +- .../lookup/fail_todo_undefined_impl.carbon | 4 +- .../check/testdata/impl/lookup/generic.carbon | 32 ++++++------ .../impl/lookup/instance_method.carbon | 4 +- .../impl/lookup/no_prelude/impl_forall.carbon | 14 ++--- .../impl/lookup/no_prelude/import.carbon | 36 ++++++------- .../testdata/impl/multiple_extend.carbon | 32 ++++++------ .../testdata/impl/no_prelude/basic.carbon | 4 +- .../impl/no_prelude/import_extend_impl.carbon | 6 +-- .../impl/no_prelude/import_self.carbon | 6 +-- .../impl/no_prelude/import_use_generic.carbon | 6 +-- .../impl/no_prelude/interface_args.carbon | 52 +++++++++---------- .../impl/no_prelude/self_in_class.carbon | 4 +- .../impl/no_prelude/self_in_signature.carbon | 8 +-- .../testdata/interface/assoc_const.carbon | 8 +-- .../fail_assoc_const_bad_default.carbon | 4 +- .../fail_todo_assoc_const_default.carbon | 8 +-- .../fail_todo_define_default_fn_inline.carbon | 8 +-- ..._todo_define_default_fn_out_of_line.carbon | 8 +-- .../no_prelude/assoc_const_in_generic.carbon | 10 ++-- .../interface/no_prelude/basic.carbon | 4 +- .../interface/no_prelude/default_fn.carbon | 4 +- .../no_prelude/fail_duplicate.carbon | 8 +-- .../no_prelude/fail_lookup_undefined.carbon | 4 +- .../no_prelude/fail_member_lookup.carbon | 8 +-- .../no_prelude/fail_modifiers.carbon | 8 +-- .../no_prelude/fail_redeclare_member.carbon | 4 +- .../no_prelude/fail_todo_facet_lookup.carbon | 4 +- .../fail_todo_generic_default_fn.carbon | 6 +-- .../no_prelude/fail_todo_modifiers.carbon | 8 +-- .../interface/no_prelude/generic.carbon | 8 +-- .../generic_binding_after_assoc_const.carbon | 12 ++--- .../no_prelude/generic_import.carbon | 12 ++--- .../interface/no_prelude/import.carbon | 24 ++++----- .../testdata/interface/no_prelude/self.carbon | 4 +- .../interface/todo_define_not_default.carbon | 16 +++--- .../testdata/let/compile_time_bindings.carbon | 8 +-- .../overloaded/no_prelude/index.carbon | 8 +-- .../packages/implicit_imports_prelude.carbon | 12 ++--- .../check/testdata/pointer/import.carbon | 12 ++--- .../no_prelude/import_convert_function.carbon | 28 +++++----- toolchain/check/testdata/struct/import.carbon | 46 ++++++++-------- toolchain/check/testdata/tuple/import.carbon | 46 ++++++++-------- .../testdata/where_expr/constraints.carbon | 18 +++---- .../testdata/where_expr/designator.carbon | 8 +-- .../testdata/where_expr/non_generic.carbon | 4 +- toolchain/docs/check.md | 14 +++-- toolchain/sem_ir/typed_insts.h | 4 +- 66 files changed, 386 insertions(+), 378 deletions(-) diff --git a/toolchain/check/import_ref.cpp b/toolchain/check/import_ref.cpp index d881f4a00d2f9..03b8ec17d6833 100644 --- a/toolchain/check/import_ref.cpp +++ b/toolchain/check/import_ref.cpp @@ -1265,8 +1265,8 @@ static auto TryResolveTypedInst(ImportRefResolver& resolver, return ResolveAs( resolver, {.type_id = resolver.local_context().GetTypeIdForTypeConstant( type_const_id), - .index = inst.index, - .decl_id = decl_id}); + .decl_id = decl_id, + .index = inst.index}); } static auto TryResolveTypedInst(ImportRefResolver& resolver, diff --git a/toolchain/check/interface.cpp b/toolchain/check/interface.cpp index 03cb7b44e169a..a1df73cffab17 100644 --- a/toolchain/check/interface.cpp +++ b/toolchain/check/interface.cpp @@ -36,7 +36,7 @@ auto BuildAssociatedEntity(Context& context, SemIR::InterfaceId interface_id, self_type_id, context.insts().Get(decl_id).type_id()); return context.AddInst( context.insts().GetLocId(decl_id), - {.type_id = type_id, .index = index, .decl_id = decl_id}); + {.type_id = type_id, .decl_id = decl_id, .index = index}); } } // namespace Carbon::Check diff --git a/toolchain/check/testdata/class/generic/import.carbon b/toolchain/check/testdata/class/generic/import.carbon index f5bfbb69822f3..6456f2fd6aaf9 100644 --- a/toolchain/check/testdata/class/generic/import.carbon +++ b/toolchain/check/testdata/class/generic/import.carbon @@ -267,7 +267,7 @@ class Class(U:! type) { // CHECK:STDOUT: %Convert.1: %Convert.type.1 = struct_value () [symbolic] // CHECK:STDOUT: %.1: type = facet_access_type %Self.2 [symbolic] // CHECK:STDOUT: %.2: type = assoc_entity_type %ImplicitAs.type.2, %Convert.type.1 [symbolic] -// CHECK:STDOUT: %.3: %.2 = assoc_entity element0, imports.%import_ref.10 [symbolic] +// CHECK:STDOUT: %.3: %.2 = assoc_entity imports.%import_ref.10, element0 [symbolic] // CHECK:STDOUT: %Convert.type.2: type = fn_type @Convert.2, @impl.1(%N) [symbolic] // CHECK:STDOUT: %Convert.2: %Convert.type.2 = struct_value () [symbolic] // CHECK:STDOUT: %.4: = interface_witness (%Convert.2) [symbolic] @@ -284,7 +284,7 @@ class Class(U:! type) { // CHECK:STDOUT: %Convert.type.5: type = fn_type @Convert.1, @ImplicitAs(Core.IntLiteral) [template] // CHECK:STDOUT: %Convert.5: %Convert.type.5 = struct_value () [template] // CHECK:STDOUT: %.8: type = assoc_entity_type %ImplicitAs.type.5, %Convert.type.5 [template] -// CHECK:STDOUT: %.9: %.8 = assoc_entity element0, imports.%import_ref.17 [template] +// CHECK:STDOUT: %.9: %.8 = assoc_entity imports.%import_ref.17, element0 [template] // CHECK:STDOUT: %Convert.type.6: type = fn_type @Convert.5, @impl.4(%N) [symbolic] // CHECK:STDOUT: %Convert.6: %Convert.type.6 = struct_value () [symbolic] // CHECK:STDOUT: %.10: = interface_witness (%Convert.6) [symbolic] @@ -296,7 +296,7 @@ class Class(U:! type) { // CHECK:STDOUT: %Convert.7: %Convert.type.7 = struct_value () [symbolic] // CHECK:STDOUT: %.11: type = facet_access_type %Self.4 [symbolic] // CHECK:STDOUT: %.12: type = assoc_entity_type %As.type.2, %Convert.type.7 [symbolic] -// CHECK:STDOUT: %.13: %.12 = assoc_entity element0, imports.%import_ref.27 [symbolic] +// CHECK:STDOUT: %.13: %.12 = assoc_entity imports.%import_ref.27, element0 [symbolic] // CHECK:STDOUT: %Convert.type.8: type = fn_type @Convert.7, @impl.5(%N) [symbolic] // CHECK:STDOUT: %Convert.8: %Convert.type.8 = struct_value () [symbolic] // CHECK:STDOUT: %.14: = interface_witness (%Convert.8) [symbolic] @@ -312,7 +312,7 @@ class Class(U:! type) { // CHECK:STDOUT: %Convert.type.11: type = fn_type @Convert.6, @As(Core.IntLiteral) [template] // CHECK:STDOUT: %Convert.11: %Convert.type.11 = struct_value () [template] // CHECK:STDOUT: %.18: type = assoc_entity_type %As.type.5, %Convert.type.11 [template] -// CHECK:STDOUT: %.19: %.18 = assoc_entity element0, imports.%import_ref.34 [template] +// CHECK:STDOUT: %.19: %.18 = assoc_entity imports.%import_ref.34, element0 [template] // CHECK:STDOUT: %Convert.type.12: type = fn_type @Convert.10, @impl.8(%N) [symbolic] // CHECK:STDOUT: %Convert.12: %Convert.type.12 = struct_value () [symbolic] // CHECK:STDOUT: %.20: = interface_witness (%Convert.12) [symbolic] @@ -346,8 +346,8 @@ class Class(U:! type) { // CHECK:STDOUT: %Convert.type.13: type = fn_type @Convert.1, @ImplicitAs(%i32) [template] // CHECK:STDOUT: %Convert.13: %Convert.type.13 = struct_value () [template] // CHECK:STDOUT: %.32: type = assoc_entity_type %ImplicitAs.type.6, %Convert.type.13 [template] -// CHECK:STDOUT: %.33: %.32 = assoc_entity element0, imports.%import_ref.10 [template] -// CHECK:STDOUT: %.34: %.2 = assoc_entity element0, imports.%import_ref.43 [symbolic] +// CHECK:STDOUT: %.33: %.32 = assoc_entity imports.%import_ref.10, element0 [template] +// CHECK:STDOUT: %.34: %.2 = assoc_entity imports.%import_ref.43, element0 [symbolic] // CHECK:STDOUT: %Convert.type.14: type = fn_type @Convert.2, @impl.1(%.24) [template] // CHECK:STDOUT: %Convert.14: %Convert.type.14 = struct_value () [template] // CHECK:STDOUT: %.35: = interface_witness (%Convert.14) [template] @@ -444,7 +444,7 @@ class Class(U:! type) { // CHECK:STDOUT: %Convert.type: type = fn_type @Convert.1, @ImplicitAs(%Dest) [symbolic = %Convert.type (constants.%Convert.type.1)] // CHECK:STDOUT: %Convert: @ImplicitAs.%Convert.type (%Convert.type.1) = struct_value () [symbolic = %Convert (constants.%Convert.1)] // CHECK:STDOUT: %.1: type = assoc_entity_type @ImplicitAs.%ImplicitAs.type (%ImplicitAs.type.2), @ImplicitAs.%Convert.type (%Convert.type.1) [symbolic = %.1 (constants.%.2)] -// CHECK:STDOUT: %.2: @ImplicitAs.%.1 (%.2) = assoc_entity element0, imports.%import_ref.10 [symbolic = %.2 (constants.%.3)] +// CHECK:STDOUT: %.2: @ImplicitAs.%.1 (%.2) = assoc_entity imports.%import_ref.10, element0 [symbolic = %.2 (constants.%.3)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: !members: @@ -464,7 +464,7 @@ class Class(U:! type) { // CHECK:STDOUT: %Convert.type: type = fn_type @Convert.6, @As(%Dest) [symbolic = %Convert.type (constants.%Convert.type.7)] // CHECK:STDOUT: %Convert: @As.%Convert.type (%Convert.type.7) = struct_value () [symbolic = %Convert (constants.%Convert.7)] // CHECK:STDOUT: %.1: type = assoc_entity_type @As.%As.type (%As.type.2), @As.%Convert.type (%Convert.type.7) [symbolic = %.1 (constants.%.12)] -// CHECK:STDOUT: %.2: @As.%.1 (%.12) = assoc_entity element0, imports.%import_ref.27 [symbolic = %.2 (constants.%.13)] +// CHECK:STDOUT: %.2: @As.%.1 (%.12) = assoc_entity imports.%import_ref.27, element0 [symbolic = %.2 (constants.%.13)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: !members: @@ -1320,7 +1320,7 @@ class Class(U:! type) { // CHECK:STDOUT: %Convert.8: %Convert.type.8 = struct_value () [symbolic] // CHECK:STDOUT: %.22: type = facet_access_type %Self.4 [symbolic] // CHECK:STDOUT: %.23: type = assoc_entity_type %As.type.2, %Convert.type.8 [symbolic] -// CHECK:STDOUT: %.24: %.23 = assoc_entity element0, imports.%import_ref.33 [symbolic] +// CHECK:STDOUT: %.24: %.23 = assoc_entity imports.%import_ref.33, element0 [symbolic] // CHECK:STDOUT: %Convert.type.9: type = fn_type @Convert.7, @impl.5(%N) [symbolic] // CHECK:STDOUT: %Convert.9: %Convert.type.9 = struct_value () [symbolic] // CHECK:STDOUT: %.25: = interface_witness (%Convert.9) [symbolic] @@ -1336,7 +1336,7 @@ class Class(U:! type) { // CHECK:STDOUT: %Convert.type.12: type = fn_type @Convert.6, @As(Core.IntLiteral) [template] // CHECK:STDOUT: %Convert.12: %Convert.type.12 = struct_value () [template] // CHECK:STDOUT: %.29: type = assoc_entity_type %As.type.5, %Convert.type.12 [template] -// CHECK:STDOUT: %.30: %.29 = assoc_entity element0, imports.%import_ref.40 [template] +// CHECK:STDOUT: %.30: %.29 = assoc_entity imports.%import_ref.40, element0 [template] // CHECK:STDOUT: %Convert.type.13: type = fn_type @Convert.10, @impl.8(%N) [symbolic] // CHECK:STDOUT: %Convert.13: %Convert.type.13 = struct_value () [symbolic] // CHECK:STDOUT: %.31: = interface_witness (%Convert.13) [symbolic] @@ -1408,7 +1408,7 @@ class Class(U:! type) { // CHECK:STDOUT: %Convert.type: type = fn_type @Convert.6, @As(%Dest) [symbolic = %Convert.type (constants.%Convert.type.8)] // CHECK:STDOUT: %Convert: @As.%Convert.type (%Convert.type.8) = struct_value () [symbolic = %Convert (constants.%Convert.8)] // CHECK:STDOUT: %.1: type = assoc_entity_type @As.%As.type (%As.type.2), @As.%Convert.type (%Convert.type.8) [symbolic = %.1 (constants.%.23)] -// CHECK:STDOUT: %.2: @As.%.1 (%.23) = assoc_entity element0, imports.%import_ref.33 [symbolic = %.2 (constants.%.24)] +// CHECK:STDOUT: %.2: @As.%.1 (%.23) = assoc_entity imports.%import_ref.33, element0 [symbolic = %.2 (constants.%.24)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: !members: @@ -1931,7 +1931,7 @@ class Class(U:! type) { // CHECK:STDOUT: %Convert.1: %Convert.type.1 = struct_value () [symbolic] // CHECK:STDOUT: %.1: type = facet_access_type %Self.2 [symbolic] // CHECK:STDOUT: %.2: type = assoc_entity_type %ImplicitAs.type.2, %Convert.type.1 [symbolic] -// CHECK:STDOUT: %.3: %.2 = assoc_entity element0, imports.%import_ref.10 [symbolic] +// CHECK:STDOUT: %.3: %.2 = assoc_entity imports.%import_ref.10, element0 [symbolic] // CHECK:STDOUT: %Convert.type.2: type = fn_type @Convert.2, @impl.1(%N) [symbolic] // CHECK:STDOUT: %Convert.2: %Convert.type.2 = struct_value () [symbolic] // CHECK:STDOUT: %.4: = interface_witness (%Convert.2) [symbolic] @@ -1948,7 +1948,7 @@ class Class(U:! type) { // CHECK:STDOUT: %Convert.type.5: type = fn_type @Convert.1, @ImplicitAs(Core.IntLiteral) [template] // CHECK:STDOUT: %Convert.5: %Convert.type.5 = struct_value () [template] // CHECK:STDOUT: %.8: type = assoc_entity_type %ImplicitAs.type.5, %Convert.type.5 [template] -// CHECK:STDOUT: %.9: %.8 = assoc_entity element0, imports.%import_ref.17 [template] +// CHECK:STDOUT: %.9: %.8 = assoc_entity imports.%import_ref.17, element0 [template] // CHECK:STDOUT: %Convert.type.6: type = fn_type @Convert.5, @impl.4(%N) [symbolic] // CHECK:STDOUT: %Convert.6: %Convert.type.6 = struct_value () [symbolic] // CHECK:STDOUT: %.10: = interface_witness (%Convert.6) [symbolic] @@ -1960,7 +1960,7 @@ class Class(U:! type) { // CHECK:STDOUT: %Convert.7: %Convert.type.7 = struct_value () [symbolic] // CHECK:STDOUT: %.11: type = facet_access_type %Self.4 [symbolic] // CHECK:STDOUT: %.12: type = assoc_entity_type %As.type.2, %Convert.type.7 [symbolic] -// CHECK:STDOUT: %.13: %.12 = assoc_entity element0, imports.%import_ref.27 [symbolic] +// CHECK:STDOUT: %.13: %.12 = assoc_entity imports.%import_ref.27, element0 [symbolic] // CHECK:STDOUT: %Convert.type.8: type = fn_type @Convert.7, @impl.5(%N) [symbolic] // CHECK:STDOUT: %Convert.8: %Convert.type.8 = struct_value () [symbolic] // CHECK:STDOUT: %.14: = interface_witness (%Convert.8) [symbolic] @@ -1976,7 +1976,7 @@ class Class(U:! type) { // CHECK:STDOUT: %Convert.type.11: type = fn_type @Convert.6, @As(Core.IntLiteral) [template] // CHECK:STDOUT: %Convert.11: %Convert.type.11 = struct_value () [template] // CHECK:STDOUT: %.18: type = assoc_entity_type %As.type.5, %Convert.type.11 [template] -// CHECK:STDOUT: %.19: %.18 = assoc_entity element0, imports.%import_ref.34 [template] +// CHECK:STDOUT: %.19: %.18 = assoc_entity imports.%import_ref.34, element0 [template] // CHECK:STDOUT: %Convert.type.12: type = fn_type @Convert.10, @impl.8(%N) [symbolic] // CHECK:STDOUT: %Convert.12: %Convert.type.12 = struct_value () [symbolic] // CHECK:STDOUT: %.20: = interface_witness (%Convert.12) [symbolic] @@ -2062,7 +2062,7 @@ class Class(U:! type) { // CHECK:STDOUT: %Convert.type: type = fn_type @Convert.1, @ImplicitAs(%Dest) [symbolic = %Convert.type (constants.%Convert.type.1)] // CHECK:STDOUT: %Convert: @ImplicitAs.%Convert.type (%Convert.type.1) = struct_value () [symbolic = %Convert (constants.%Convert.1)] // CHECK:STDOUT: %.1: type = assoc_entity_type @ImplicitAs.%ImplicitAs.type (%ImplicitAs.type.2), @ImplicitAs.%Convert.type (%Convert.type.1) [symbolic = %.1 (constants.%.2)] -// CHECK:STDOUT: %.2: @ImplicitAs.%.1 (%.2) = assoc_entity element0, imports.%import_ref.10 [symbolic = %.2 (constants.%.3)] +// CHECK:STDOUT: %.2: @ImplicitAs.%.1 (%.2) = assoc_entity imports.%import_ref.10, element0 [symbolic = %.2 (constants.%.3)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: !members: @@ -2082,7 +2082,7 @@ class Class(U:! type) { // CHECK:STDOUT: %Convert.type: type = fn_type @Convert.6, @As(%Dest) [symbolic = %Convert.type (constants.%Convert.type.7)] // CHECK:STDOUT: %Convert: @As.%Convert.type (%Convert.type.7) = struct_value () [symbolic = %Convert (constants.%Convert.7)] // CHECK:STDOUT: %.1: type = assoc_entity_type @As.%As.type (%As.type.2), @As.%Convert.type (%Convert.type.7) [symbolic = %.1 (constants.%.12)] -// CHECK:STDOUT: %.2: @As.%.1 (%.12) = assoc_entity element0, imports.%import_ref.27 [symbolic = %.2 (constants.%.13)] +// CHECK:STDOUT: %.2: @As.%.1 (%.12) = assoc_entity imports.%import_ref.27, element0 [symbolic = %.2 (constants.%.13)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: !members: diff --git a/toolchain/check/testdata/function/builtin/method.carbon b/toolchain/check/testdata/function/builtin/method.carbon index a0f3618bd78b5..543f2f80dc36d 100644 --- a/toolchain/check/testdata/function/builtin/method.carbon +++ b/toolchain/check/testdata/function/builtin/method.carbon @@ -27,7 +27,7 @@ var arr: [i32; (1 as i32).(I.F)(2)]; // CHECK:STDOUT: %F.type.1: type = fn_type @F.1 [template] // CHECK:STDOUT: %F.1: %F.type.1 = struct_value () [template] // CHECK:STDOUT: %.2: type = assoc_entity_type %I.type, %F.type.1 [template] -// CHECK:STDOUT: %.3: %.2 = assoc_entity element0, @I.%F.decl [template] +// CHECK:STDOUT: %.3: %.2 = assoc_entity @I.%F.decl, element0 [template] // CHECK:STDOUT: %.4: Core.IntLiteral = int_value 32 [template] // CHECK:STDOUT: %Int.type: type = fn_type @Int [template] // CHECK:STDOUT: %Int: %Int.type = struct_value () [template] @@ -155,7 +155,7 @@ var arr: [i32; (1 as i32).(I.F)(2)]; // CHECK:STDOUT: %return.param: ref @F.1.%.loc12_14.1 (%.1) = out_param runtime_param2 // CHECK:STDOUT: %return: ref @F.1.%.loc12_14.1 (%.1) = return_slot %return.param // CHECK:STDOUT: } -// CHECK:STDOUT: %.loc12: %.2 = assoc_entity element0, %F.decl [template = constants.%.3] +// CHECK:STDOUT: %.loc12: %.2 = assoc_entity %F.decl, element0 [template = constants.%.3] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self diff --git a/toolchain/check/testdata/function/builtin/no_prelude/call_from_operator.carbon b/toolchain/check/testdata/function/builtin/no_prelude/call_from_operator.carbon index f2c841aaac431..702eb8c170985 100644 --- a/toolchain/check/testdata/function/builtin/no_prelude/call_from_operator.carbon +++ b/toolchain/check/testdata/function/builtin/no_prelude/call_from_operator.carbon @@ -62,7 +62,7 @@ var arr: [i32; (1 as i32) + (2 as i32)] = (3, 4, (3 as i32) + (4 as i32)); // CHECK:STDOUT: %Op.type.1: type = fn_type @Op.1 [template] // CHECK:STDOUT: %Op.1: %Op.type.1 = struct_value () [template] // CHECK:STDOUT: %.2: type = assoc_entity_type %Add.type, %Op.type.1 [template] -// CHECK:STDOUT: %.3: %.2 = assoc_entity element0, @Add.%Op.decl [template] +// CHECK:STDOUT: %.3: %.2 = assoc_entity @Add.%Op.decl, element0 [template] // CHECK:STDOUT: %T: type = bind_symbolic_name T, 0 [symbolic] // CHECK:STDOUT: %T.patt: type = symbolic_binding_pattern T, 0 [symbolic] // CHECK:STDOUT: %As.type.1: type = generic_interface_type @As [template] @@ -73,7 +73,7 @@ var arr: [i32; (1 as i32) + (2 as i32)] = (3, 4, (3 as i32) + (4 as i32)); // CHECK:STDOUT: %Convert.type.1: type = fn_type @Convert.1, @As(%T) [symbolic] // CHECK:STDOUT: %Convert.1: %Convert.type.1 = struct_value () [symbolic] // CHECK:STDOUT: %.5: type = assoc_entity_type %As.type.2, %Convert.type.1 [symbolic] -// CHECK:STDOUT: %.6: %.5 = assoc_entity element0, @As.%Convert.decl [symbolic] +// CHECK:STDOUT: %.6: %.5 = assoc_entity @As.%Convert.decl, element0 [symbolic] // CHECK:STDOUT: %ImplicitAs.type.1: type = generic_interface_type @ImplicitAs [template] // CHECK:STDOUT: %ImplicitAs: %ImplicitAs.type.1 = struct_value () [template] // CHECK:STDOUT: %ImplicitAs.type.2: type = facet_type <@ImplicitAs, @ImplicitAs(%T)> [symbolic] @@ -82,7 +82,7 @@ var arr: [i32; (1 as i32) + (2 as i32)] = (3, 4, (3 as i32) + (4 as i32)); // CHECK:STDOUT: %Convert.type.2: type = fn_type @Convert.2, @ImplicitAs(%T) [symbolic] // CHECK:STDOUT: %Convert.2: %Convert.type.2 = struct_value () [symbolic] // CHECK:STDOUT: %.8: type = assoc_entity_type %ImplicitAs.type.2, %Convert.type.2 [symbolic] -// CHECK:STDOUT: %.9: %.8 = assoc_entity element0, @ImplicitAs.%Convert.decl [symbolic] +// CHECK:STDOUT: %.9: %.8 = assoc_entity @ImplicitAs.%Convert.decl, element0 [symbolic] // CHECK:STDOUT: %.10: Core.IntLiteral = int_value 32 [template] // CHECK:STDOUT: %i32: type = int_type signed, %.10 [template] // CHECK:STDOUT: %Op.type.2: type = fn_type @Op.2 [template] @@ -95,7 +95,7 @@ var arr: [i32; (1 as i32) + (2 as i32)] = (3, 4, (3 as i32) + (4 as i32)); // CHECK:STDOUT: %Convert.type.4: type = fn_type @Convert.1, @As(%i32) [template] // CHECK:STDOUT: %Convert.4: %Convert.type.4 = struct_value () [template] // CHECK:STDOUT: %.13: type = assoc_entity_type %As.type.3, %Convert.type.4 [template] -// CHECK:STDOUT: %.14: %.13 = assoc_entity element0, @As.%Convert.decl [template] +// CHECK:STDOUT: %.14: %.13 = assoc_entity @As.%Convert.decl, element0 [template] // CHECK:STDOUT: %.15: %As.type.2 = facet_value Core.IntLiteral, Core.IntLiteral [symbolic] // CHECK:STDOUT: %.16: = interface_witness (%Convert.3) [template] // CHECK:STDOUT: %ImplicitAs.type.3: type = facet_type <@ImplicitAs, @ImplicitAs(%i32)> [template] @@ -104,7 +104,7 @@ var arr: [i32; (1 as i32) + (2 as i32)] = (3, 4, (3 as i32) + (4 as i32)); // CHECK:STDOUT: %Convert.type.6: type = fn_type @Convert.2, @ImplicitAs(%i32) [template] // CHECK:STDOUT: %Convert.6: %Convert.type.6 = struct_value () [template] // CHECK:STDOUT: %.17: type = assoc_entity_type %ImplicitAs.type.3, %Convert.type.6 [template] -// CHECK:STDOUT: %.18: %.17 = assoc_entity element0, @ImplicitAs.%Convert.decl [template] +// CHECK:STDOUT: %.18: %.17 = assoc_entity @ImplicitAs.%Convert.decl, element0 [template] // CHECK:STDOUT: %.19: %ImplicitAs.type.2 = facet_value Core.IntLiteral, Core.IntLiteral [symbolic] // CHECK:STDOUT: %.20: = interface_witness (%Convert.5) [template] // CHECK:STDOUT: %ImplicitAs.type.4: type = facet_type <@ImplicitAs, @ImplicitAs(Core.IntLiteral)> [template] @@ -113,7 +113,7 @@ var arr: [i32; (1 as i32) + (2 as i32)] = (3, 4, (3 as i32) + (4 as i32)); // CHECK:STDOUT: %Convert.type.8: type = fn_type @Convert.2, @ImplicitAs(Core.IntLiteral) [template] // CHECK:STDOUT: %Convert.8: %Convert.type.8 = struct_value () [template] // CHECK:STDOUT: %.21: type = assoc_entity_type %ImplicitAs.type.4, %Convert.type.8 [template] -// CHECK:STDOUT: %.22: %.21 = assoc_entity element0, @ImplicitAs.%Convert.decl [template] +// CHECK:STDOUT: %.22: %.21 = assoc_entity @ImplicitAs.%Convert.decl, element0 [template] // CHECK:STDOUT: %.23: %ImplicitAs.type.2 = facet_value %i32, %i32 [symbolic] // CHECK:STDOUT: %.24: = interface_witness (%Convert.7) [template] // CHECK:STDOUT: } @@ -234,7 +234,7 @@ var arr: [i32; (1 as i32) + (2 as i32)] = (3, 4, (3 as i32) + (4 as i32)); // CHECK:STDOUT: %return.param: ref @Op.1.%.loc8_15.1 (%.1) = out_param runtime_param2 // CHECK:STDOUT: %return: ref @Op.1.%.loc8_15.1 (%.1) = return_slot %return.param // CHECK:STDOUT: } -// CHECK:STDOUT: %.loc8: %.2 = assoc_entity element0, %Op.decl [template = constants.%.3] +// CHECK:STDOUT: %.loc8: %.2 = assoc_entity %Op.decl, element0 [template = constants.%.3] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self @@ -252,7 +252,7 @@ var arr: [i32; (1 as i32) + (2 as i32)] = (3, 4, (3 as i32) + (4 as i32)); // CHECK:STDOUT: %Convert.type: type = fn_type @Convert.1, @As(%T.loc11_14.2) [symbolic = %Convert.type (constants.%Convert.type.1)] // CHECK:STDOUT: %Convert: @As.%Convert.type (%Convert.type.1) = struct_value () [symbolic = %Convert (constants.%Convert.1)] // CHECK:STDOUT: %.loc12_32.2: type = assoc_entity_type @As.%As.type (%As.type.2), @As.%Convert.type (%Convert.type.1) [symbolic = %.loc12_32.2 (constants.%.5)] -// CHECK:STDOUT: %.loc12_32.3: @As.%.loc12_32.2 (%.5) = assoc_entity element0, %Convert.decl [symbolic = %.loc12_32.3 (constants.%.6)] +// CHECK:STDOUT: %.loc12_32.3: @As.%.loc12_32.2 (%.5) = assoc_entity %Convert.decl, element0 [symbolic = %.loc12_32.3 (constants.%.6)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: %Self.1: @As.%As.type (%As.type.2) = bind_symbolic_name Self, 1 [symbolic = %Self.2 (constants.%Self.2)] @@ -272,7 +272,7 @@ var arr: [i32; (1 as i32) + (2 as i32)] = (3, 4, (3 as i32) + (4 as i32)); // CHECK:STDOUT: %return.param: ref @Convert.1.%T (%T) = out_param runtime_param1 // CHECK:STDOUT: %return: ref @Convert.1.%T (%T) = return_slot %return.param // CHECK:STDOUT: } -// CHECK:STDOUT: %.loc12_32.1: @As.%.loc12_32.2 (%.5) = assoc_entity element0, %Convert.decl [symbolic = %.loc12_32.3 (constants.%.6)] +// CHECK:STDOUT: %.loc12_32.1: @As.%.loc12_32.2 (%.5) = assoc_entity %Convert.decl, element0 [symbolic = %.loc12_32.3 (constants.%.6)] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self.1 @@ -291,7 +291,7 @@ var arr: [i32; (1 as i32) + (2 as i32)] = (3, 4, (3 as i32) + (4 as i32)); // CHECK:STDOUT: %Convert.type: type = fn_type @Convert.2, @ImplicitAs(%T.loc15_22.2) [symbolic = %Convert.type (constants.%Convert.type.2)] // CHECK:STDOUT: %Convert: @ImplicitAs.%Convert.type (%Convert.type.2) = struct_value () [symbolic = %Convert (constants.%Convert.2)] // CHECK:STDOUT: %.loc16_32.2: type = assoc_entity_type @ImplicitAs.%ImplicitAs.type (%ImplicitAs.type.2), @ImplicitAs.%Convert.type (%Convert.type.2) [symbolic = %.loc16_32.2 (constants.%.8)] -// CHECK:STDOUT: %.loc16_32.3: @ImplicitAs.%.loc16_32.2 (%.8) = assoc_entity element0, %Convert.decl [symbolic = %.loc16_32.3 (constants.%.9)] +// CHECK:STDOUT: %.loc16_32.3: @ImplicitAs.%.loc16_32.2 (%.8) = assoc_entity %Convert.decl, element0 [symbolic = %.loc16_32.3 (constants.%.9)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: %Self.1: @ImplicitAs.%ImplicitAs.type (%ImplicitAs.type.2) = bind_symbolic_name Self, 1 [symbolic = %Self.2 (constants.%Self.3)] @@ -311,7 +311,7 @@ var arr: [i32; (1 as i32) + (2 as i32)] = (3, 4, (3 as i32) + (4 as i32)); // CHECK:STDOUT: %return.param: ref @Convert.2.%T (%T) = out_param runtime_param1 // CHECK:STDOUT: %return: ref @Convert.2.%T (%T) = return_slot %return.param // CHECK:STDOUT: } -// CHECK:STDOUT: %.loc16_32.1: @ImplicitAs.%.loc16_32.2 (%.8) = assoc_entity element0, %Convert.decl [symbolic = %.loc16_32.3 (constants.%.9)] +// CHECK:STDOUT: %.loc16_32.1: @ImplicitAs.%.loc16_32.2 (%.8) = assoc_entity %Convert.decl, element0 [symbolic = %.loc16_32.3 (constants.%.9)] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self.1 @@ -586,14 +586,14 @@ var arr: [i32; (1 as i32) + (2 as i32)] = (3, 4, (3 as i32) + (4 as i32)); // CHECK:STDOUT: %Convert.1: %Convert.type.1 = struct_value () [symbolic] // CHECK:STDOUT: %.3: type = facet_access_type %Self.2 [symbolic] // CHECK:STDOUT: %.4: type = assoc_entity_type %As.type.2, %Convert.type.1 [symbolic] -// CHECK:STDOUT: %.5: %.4 = assoc_entity element0, imports.%import_ref.6 [symbolic] +// CHECK:STDOUT: %.5: %.4 = assoc_entity imports.%import_ref.6, element0 [symbolic] // CHECK:STDOUT: %.6: type = facet_access_type %Self.1 [symbolic] // CHECK:STDOUT: %As.type.3: type = facet_type <@As, @As(%i32)> [template] // CHECK:STDOUT: %Convert.type.2: type = fn_type @Convert.1, @As(%i32) [template] // CHECK:STDOUT: %Convert.2: %Convert.type.2 = struct_value () [template] // CHECK:STDOUT: %.7: type = assoc_entity_type %As.type.3, %Convert.type.2 [template] -// CHECK:STDOUT: %.8: %.7 = assoc_entity element0, imports.%import_ref.6 [template] -// CHECK:STDOUT: %.9: %.4 = assoc_entity element0, imports.%import_ref.7 [symbolic] +// CHECK:STDOUT: %.8: %.7 = assoc_entity imports.%import_ref.6, element0 [template] +// CHECK:STDOUT: %.9: %.4 = assoc_entity imports.%import_ref.7, element0 [symbolic] // CHECK:STDOUT: %Add.type: type = facet_type <@Add> [template] // CHECK:STDOUT: %Self.3: %Add.type = bind_symbolic_name Self, 0 [symbolic] // CHECK:STDOUT: %ImplicitAs.type.2: type = facet_type <@ImplicitAs, @ImplicitAs(%T)> [symbolic] @@ -604,17 +604,17 @@ var arr: [i32; (1 as i32) + (2 as i32)] = (3, 4, (3 as i32) + (4 as i32)); // CHECK:STDOUT: %Convert.3: %Convert.type.3 = struct_value () [symbolic] // CHECK:STDOUT: %.10: type = facet_access_type %Self.5 [symbolic] // CHECK:STDOUT: %.11: type = assoc_entity_type %ImplicitAs.type.2, %Convert.type.3 [symbolic] -// CHECK:STDOUT: %.12: %.11 = assoc_entity element0, imports.%import_ref.23 [symbolic] +// CHECK:STDOUT: %.12: %.11 = assoc_entity imports.%import_ref.23, element0 [symbolic] // CHECK:STDOUT: %.13: type = facet_access_type %Self.4 [symbolic] // CHECK:STDOUT: %Convert.type.4: type = fn_type @Convert.2, @ImplicitAs(%i32) [template] // CHECK:STDOUT: %Convert.4: %Convert.type.4 = struct_value () [template] // CHECK:STDOUT: %.14: type = assoc_entity_type %ImplicitAs.type.3, %Convert.type.4 [template] -// CHECK:STDOUT: %.15: %.14 = assoc_entity element0, imports.%import_ref.24 [template] +// CHECK:STDOUT: %.15: %.14 = assoc_entity imports.%import_ref.24, element0 [template] // CHECK:STDOUT: %ImplicitAs.type.4: type = facet_type <@ImplicitAs, @ImplicitAs(Core.IntLiteral)> [template] // CHECK:STDOUT: %Convert.type.5: type = fn_type @Convert.2, @ImplicitAs(Core.IntLiteral) [template] // CHECK:STDOUT: %Convert.5: %Convert.type.5 = struct_value () [template] // CHECK:STDOUT: %.16: type = assoc_entity_type %ImplicitAs.type.4, %Convert.type.5 [template] -// CHECK:STDOUT: %.17: %.16 = assoc_entity element0, imports.%import_ref.28 [template] +// CHECK:STDOUT: %.17: %.16 = assoc_entity imports.%import_ref.28, element0 [template] // CHECK:STDOUT: %Convert.type.6: type = fn_type @Convert.3 [template] // CHECK:STDOUT: %Convert.6: %Convert.type.6 = struct_value () [template] // CHECK:STDOUT: %.18: = interface_witness (%Convert.6) [template] @@ -626,13 +626,13 @@ var arr: [i32; (1 as i32) + (2 as i32)] = (3, 4, (3 as i32) + (4 as i32)); // CHECK:STDOUT: %Op.type.1: type = fn_type @Op.1 [template] // CHECK:STDOUT: %.24: type = facet_access_type %Self.3 [symbolic] // CHECK:STDOUT: %.25: type = assoc_entity_type %Add.type, %Op.type.1 [template] -// CHECK:STDOUT: %.26: %.25 = assoc_entity element0, imports.%import_ref.30 [template] +// CHECK:STDOUT: %.26: %.25 = assoc_entity imports.%import_ref.30, element0 [template] // CHECK:STDOUT: %Op.type.2: type = fn_type @Op.2 [template] // CHECK:STDOUT: %Op.2: %Op.type.2 = struct_value () [template] // CHECK:STDOUT: %.27: = interface_witness (%Op.2) [template] // CHECK:STDOUT: %.28: = bound_method %.20, %Op.2 [template] // CHECK:STDOUT: %.29: %i32 = int_value 3 [template] -// CHECK:STDOUT: %.30: %.11 = assoc_entity element0, imports.%import_ref.32 [symbolic] +// CHECK:STDOUT: %.30: %.11 = assoc_entity imports.%import_ref.32, element0 [symbolic] // CHECK:STDOUT: %Convert.type.7: type = fn_type @Convert.4 [template] // CHECK:STDOUT: %Convert.7: %Convert.type.7 = struct_value () [template] // CHECK:STDOUT: %.31: = interface_witness (%Convert.7) [template] @@ -743,7 +743,7 @@ var arr: [i32; (1 as i32) + (2 as i32)] = (3, 4, (3 as i32) + (4 as i32)); // CHECK:STDOUT: %Convert.type: type = fn_type @Convert.1, @As(%T) [symbolic = %Convert.type (constants.%Convert.type.1)] // CHECK:STDOUT: %Convert: @As.%Convert.type (%Convert.type.1) = struct_value () [symbolic = %Convert (constants.%Convert.1)] // CHECK:STDOUT: %.1: type = assoc_entity_type @As.%As.type (%As.type.2), @As.%Convert.type (%Convert.type.1) [symbolic = %.1 (constants.%.4)] -// CHECK:STDOUT: %.2: @As.%.1 (%.4) = assoc_entity element0, imports.%import_ref.6 [symbolic = %.2 (constants.%.5)] +// CHECK:STDOUT: %.2: @As.%.1 (%.4) = assoc_entity imports.%import_ref.6, element0 [symbolic = %.2 (constants.%.5)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: !members: @@ -770,7 +770,7 @@ var arr: [i32; (1 as i32) + (2 as i32)] = (3, 4, (3 as i32) + (4 as i32)); // CHECK:STDOUT: %Convert.type: type = fn_type @Convert.2, @ImplicitAs(%T) [symbolic = %Convert.type (constants.%Convert.type.3)] // CHECK:STDOUT: %Convert: @ImplicitAs.%Convert.type (%Convert.type.3) = struct_value () [symbolic = %Convert (constants.%Convert.3)] // CHECK:STDOUT: %.1: type = assoc_entity_type @ImplicitAs.%ImplicitAs.type (%ImplicitAs.type.2), @ImplicitAs.%Convert.type (%Convert.type.3) [symbolic = %.1 (constants.%.11)] -// CHECK:STDOUT: %.2: @ImplicitAs.%.1 (%.11) = assoc_entity element0, imports.%import_ref.23 [symbolic = %.2 (constants.%.12)] +// CHECK:STDOUT: %.2: @ImplicitAs.%.1 (%.11) = assoc_entity imports.%import_ref.23, element0 [symbolic = %.2 (constants.%.12)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: !members: diff --git a/toolchain/check/testdata/impl/compound.carbon b/toolchain/check/testdata/impl/compound.carbon index 8363d6d15a9ac..e45fb85fe6b68 100644 --- a/toolchain/check/testdata/impl/compound.carbon +++ b/toolchain/check/testdata/impl/compound.carbon @@ -43,12 +43,12 @@ fn InstanceCallIndirect(p: i32*) { // CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [template] // CHECK:STDOUT: %F.1: %F.type.1 = struct_value () [template] // CHECK:STDOUT: %.1: type = assoc_entity_type %Simple.type, %F.type.1 [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @Simple.%F.decl [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @Simple.%F.decl, element0 [template] // CHECK:STDOUT: %.3: type = facet_access_type %Self [symbolic] // CHECK:STDOUT: %G.type.1: type = fn_type @G.1 [template] // CHECK:STDOUT: %G.1: %G.type.1 = struct_value () [template] // CHECK:STDOUT: %.4: type = assoc_entity_type %Simple.type, %G.type.1 [template] -// CHECK:STDOUT: %.5: %.4 = assoc_entity element1, @Simple.%G.decl [template] +// CHECK:STDOUT: %.5: %.4 = assoc_entity @Simple.%G.decl, element1 [template] // CHECK:STDOUT: %.6: Core.IntLiteral = int_value 32 [template] // CHECK:STDOUT: %Int.type: type = fn_type @Int [template] // CHECK:STDOUT: %Int: %Int.type = struct_value () [template] @@ -147,7 +147,7 @@ fn InstanceCallIndirect(p: i32*) { // CHECK:STDOUT: interface @Simple { // CHECK:STDOUT: %Self: %Simple.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self] // CHECK:STDOUT: %F.decl: %F.type.1 = fn_decl @F.1 [template = constants.%F.1] {} {} -// CHECK:STDOUT: %.loc12: %.1 = assoc_entity element0, %F.decl [template = constants.%.2] +// CHECK:STDOUT: %.loc12: %.1 = assoc_entity %F.decl, element0 [template = constants.%.2] // CHECK:STDOUT: %G.decl: %G.type.1 = fn_decl @G.1 [template = constants.%G.1] { // CHECK:STDOUT: %self.patt: @G.1.%.loc13_14.1 (%.3) = binding_pattern self // CHECK:STDOUT: %self.param_patt: @G.1.%.loc13_14.1 (%.3) = value_param_pattern %self.patt, runtime_param0 @@ -158,7 +158,7 @@ fn InstanceCallIndirect(p: i32*) { // CHECK:STDOUT: %self.param: @G.1.%.loc13_14.1 (%.3) = value_param runtime_param0 // CHECK:STDOUT: %self: @G.1.%.loc13_14.1 (%.3) = bind_name self, %self.param // CHECK:STDOUT: } -// CHECK:STDOUT: %.loc13: %.4 = assoc_entity element1, %G.decl [template = constants.%.5] +// CHECK:STDOUT: %.loc13: %.4 = assoc_entity %G.decl, element1 [template = constants.%.5] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self diff --git a/toolchain/check/testdata/impl/extend_impl.carbon b/toolchain/check/testdata/impl/extend_impl.carbon index 7f228cf3752cf..5701568c93566 100644 --- a/toolchain/check/testdata/impl/extend_impl.carbon +++ b/toolchain/check/testdata/impl/extend_impl.carbon @@ -32,7 +32,7 @@ fn G(c: C) { // CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [template] // CHECK:STDOUT: %F.1: %F.type.1 = struct_value () [template] // CHECK:STDOUT: %.1: type = assoc_entity_type %HasF.type, %F.type.1 [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @HasF.%F.decl [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @HasF.%F.decl, element0 [template] // CHECK:STDOUT: %C: type = class_type @C [template] // CHECK:STDOUT: %F.type.2: type = fn_type @F.2 [template] // CHECK:STDOUT: %F.2: %F.type.2 = struct_value () [template] @@ -74,7 +74,7 @@ fn G(c: C) { // CHECK:STDOUT: interface @HasF { // CHECK:STDOUT: %Self: %HasF.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self] // CHECK:STDOUT: %F.decl: %F.type.1 = fn_decl @F.1 [template = constants.%F.1] {} {} -// CHECK:STDOUT: %.loc12: %.1 = assoc_entity element0, %F.decl [template = constants.%.2] +// CHECK:STDOUT: %.loc12: %.1 = assoc_entity %F.decl, element0 [template = constants.%.2] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self diff --git a/toolchain/check/testdata/impl/extend_impl_generic.carbon b/toolchain/check/testdata/impl/extend_impl_generic.carbon index b3cbdcef73cc3..b230bbffc67a1 100644 --- a/toolchain/check/testdata/impl/extend_impl_generic.carbon +++ b/toolchain/check/testdata/impl/extend_impl_generic.carbon @@ -59,7 +59,7 @@ class X(U:! type) { // CHECK:STDOUT: %F.type.1: type = fn_type @F.1, @HasF(%T) [symbolic] // CHECK:STDOUT: %F.1: %F.type.1 = struct_value () [symbolic] // CHECK:STDOUT: %.1: type = assoc_entity_type %HasF.type.2, %F.type.1 [symbolic] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @HasF.%F.decl [symbolic] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @HasF.%F.decl, element0 [symbolic] // CHECK:STDOUT: %Param: type = class_type @Param [template] // CHECK:STDOUT: %.3: Core.IntLiteral = int_value 32 [template] // CHECK:STDOUT: %Int.type: type = fn_type @Int [template] @@ -73,7 +73,7 @@ class X(U:! type) { // CHECK:STDOUT: %F.type.2: type = fn_type @F.1, @HasF(%Param) [template] // CHECK:STDOUT: %F.2: %F.type.2 = struct_value () [template] // CHECK:STDOUT: %.7: type = assoc_entity_type %HasF.type.3, %F.type.2 [template] -// CHECK:STDOUT: %.8: %.7 = assoc_entity element0, @HasF.%F.decl [template] +// CHECK:STDOUT: %.8: %.7 = assoc_entity @HasF.%F.decl, element0 [template] // CHECK:STDOUT: %F.type.3: type = fn_type @F.2 [template] // CHECK:STDOUT: %F.3: %F.type.3 = struct_value () [template] // CHECK:STDOUT: %.9: %HasF.type.2 = facet_value %C, %C [symbolic] @@ -141,7 +141,7 @@ class X(U:! type) { // CHECK:STDOUT: %F.type: type = fn_type @F.1, @HasF(%T.loc4_16.2) [symbolic = %F.type (constants.%F.type.1)] // CHECK:STDOUT: %F: @HasF.%F.type (%F.type.1) = struct_value () [symbolic = %F (constants.%F.1)] // CHECK:STDOUT: %.loc5_14.2: type = assoc_entity_type @HasF.%HasF.type (%HasF.type.2), @HasF.%F.type (%F.type.1) [symbolic = %.loc5_14.2 (constants.%.1)] -// CHECK:STDOUT: %.loc5_14.3: @HasF.%.loc5_14.2 (%.1) = assoc_entity element0, %F.decl [symbolic = %.loc5_14.3 (constants.%.2)] +// CHECK:STDOUT: %.loc5_14.3: @HasF.%.loc5_14.2 (%.1) = assoc_entity %F.decl, element0 [symbolic = %.loc5_14.3 (constants.%.2)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: %Self.1: @HasF.%HasF.type (%HasF.type.2) = bind_symbolic_name Self, 1 [symbolic = %Self.2 (constants.%Self.1)] @@ -153,7 +153,7 @@ class X(U:! type) { // CHECK:STDOUT: %return.param: ref @F.1.%T (%T) = out_param runtime_param0 // CHECK:STDOUT: %return: ref @F.1.%T (%T) = return_slot %return.param // CHECK:STDOUT: } -// CHECK:STDOUT: %.loc5_14.1: @HasF.%.loc5_14.2 (%.1) = assoc_entity element0, %F.decl [symbolic = %.loc5_14.3 (constants.%.2)] +// CHECK:STDOUT: %.loc5_14.1: @HasF.%.loc5_14.2 (%.1) = assoc_entity %F.decl, element0 [symbolic = %.loc5_14.3 (constants.%.2)] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self.1 @@ -308,7 +308,7 @@ class X(U:! type) { // CHECK:STDOUT: %F.type.1: type = fn_type @F.1, @I(%T) [symbolic] // CHECK:STDOUT: %F.1: %F.type.1 = struct_value () [symbolic] // CHECK:STDOUT: %.2: type = assoc_entity_type %I.type.2, %F.type.1 [symbolic] -// CHECK:STDOUT: %.3: %.2 = assoc_entity element0, @I.%F.decl [symbolic] +// CHECK:STDOUT: %.3: %.2 = assoc_entity @I.%F.decl, element0 [symbolic] // CHECK:STDOUT: %U: type = bind_symbolic_name U, 0 [symbolic] // CHECK:STDOUT: %U.patt: type = symbolic_binding_pattern U, 0 [symbolic] // CHECK:STDOUT: %X.type: type = generic_class_type @X [template] @@ -318,7 +318,7 @@ class X(U:! type) { // CHECK:STDOUT: %F.type.2: type = fn_type @F.1, @I(%U) [symbolic] // CHECK:STDOUT: %F.2: %F.type.2 = struct_value () [symbolic] // CHECK:STDOUT: %.4: type = assoc_entity_type %I.type.3, %F.type.2 [symbolic] -// CHECK:STDOUT: %.5: %.4 = assoc_entity element0, @I.%F.decl [symbolic] +// CHECK:STDOUT: %.5: %.4 = assoc_entity @I.%F.decl, element0 [symbolic] // CHECK:STDOUT: %F.type.3: type = fn_type @F.2, @impl(%U) [symbolic] // CHECK:STDOUT: %F.3: %F.type.3 = struct_value () [symbolic] // CHECK:STDOUT: %.6: %I.type.2 = facet_value %X.2, %X.2 [symbolic] @@ -367,7 +367,7 @@ class X(U:! type) { // CHECK:STDOUT: %F.type: type = fn_type @F.1, @I(%T.loc4_13.2) [symbolic = %F.type (constants.%F.type.1)] // CHECK:STDOUT: %F: @I.%F.type (%F.type.1) = struct_value () [symbolic = %F (constants.%F.1)] // CHECK:STDOUT: %.loc5_25.2: type = assoc_entity_type @I.%I.type (%I.type.2), @I.%F.type (%F.type.1) [symbolic = %.loc5_25.2 (constants.%.2)] -// CHECK:STDOUT: %.loc5_25.3: @I.%.loc5_25.2 (%.2) = assoc_entity element0, %F.decl [symbolic = %.loc5_25.3 (constants.%.3)] +// CHECK:STDOUT: %.loc5_25.3: @I.%.loc5_25.2 (%.2) = assoc_entity %F.decl, element0 [symbolic = %.loc5_25.3 (constants.%.3)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: %Self.1: @I.%I.type (%I.type.2) = bind_symbolic_name Self, 1 [symbolic = %Self.2 (constants.%Self)] @@ -387,7 +387,7 @@ class X(U:! type) { // CHECK:STDOUT: %t.param: @F.1.%T (%T) = value_param runtime_param1 // CHECK:STDOUT: %t: @F.1.%T (%T) = bind_name t, %t.param // CHECK:STDOUT: } -// CHECK:STDOUT: %.loc5_25.1: @I.%.loc5_25.2 (%.2) = assoc_entity element0, %F.decl [symbolic = %.loc5_25.3 (constants.%.3)] +// CHECK:STDOUT: %.loc5_25.1: @I.%.loc5_25.2 (%.2) = assoc_entity %F.decl, element0 [symbolic = %.loc5_25.3 (constants.%.3)] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self.1 diff --git a/toolchain/check/testdata/impl/fail_call_invalid.carbon b/toolchain/check/testdata/impl/fail_call_invalid.carbon index 2b528ab5302fe..ef02d90979190 100644 --- a/toolchain/check/testdata/impl/fail_call_invalid.carbon +++ b/toolchain/check/testdata/impl/fail_call_invalid.carbon @@ -32,7 +32,7 @@ fn InstanceCall(n: i32) { // CHECK:STDOUT: %G.type.1: type = fn_type @G.1 [template] // CHECK:STDOUT: %G.1: %G.type.1 = struct_value () [template] // CHECK:STDOUT: %.2: type = assoc_entity_type %Simple.type, %G.type.1 [template] -// CHECK:STDOUT: %.3: %.2 = assoc_entity element0, @Simple.%G.decl [template] +// CHECK:STDOUT: %.3: %.2 = assoc_entity @Simple.%G.decl, element0 [template] // CHECK:STDOUT: %.4: Core.IntLiteral = int_value 32 [template] // CHECK:STDOUT: %Int.type: type = fn_type @Int [template] // CHECK:STDOUT: %Int: %Int.type = struct_value () [template] @@ -92,7 +92,7 @@ fn InstanceCall(n: i32) { // CHECK:STDOUT: %self.param: @G.1.%.loc12_14.1 (%.1) = value_param runtime_param0 // CHECK:STDOUT: %self: @G.1.%.loc12_14.1 (%.1) = bind_name self, %self.param // CHECK:STDOUT: } -// CHECK:STDOUT: %.loc12: %.2 = assoc_entity element0, %G.decl [template = constants.%.3] +// CHECK:STDOUT: %.loc12: %.2 = assoc_entity %G.decl, element0 [template = constants.%.3] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self diff --git a/toolchain/check/testdata/impl/fail_extend_impl_forall.carbon b/toolchain/check/testdata/impl/fail_extend_impl_forall.carbon index b57784c229811..2a87cb05fb5fc 100644 --- a/toolchain/check/testdata/impl/fail_extend_impl_forall.carbon +++ b/toolchain/check/testdata/impl/fail_extend_impl_forall.carbon @@ -33,7 +33,7 @@ class C { // CHECK:STDOUT: %F.type.1: type = fn_type @F.1, @GenericInterface(%T) [symbolic] // CHECK:STDOUT: %F.1: %F.type.1 = struct_value () [symbolic] // CHECK:STDOUT: %.1: type = assoc_entity_type %GenericInterface.type.2, %F.type.1 [symbolic] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @GenericInterface.%F.decl [symbolic] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @GenericInterface.%F.decl, element0 [symbolic] // CHECK:STDOUT: %C: type = class_type @C [template] // CHECK:STDOUT: %F.type.2: type = fn_type @F.2, @impl(%T) [symbolic] // CHECK:STDOUT: %F.2: %F.type.2 = struct_value () [symbolic] @@ -77,7 +77,7 @@ class C { // CHECK:STDOUT: %F.type: type = fn_type @F.1, @GenericInterface(%T.loc11_28.2) [symbolic = %F.type (constants.%F.type.1)] // CHECK:STDOUT: %F: @GenericInterface.%F.type (%F.type.1) = struct_value () [symbolic = %F (constants.%F.1)] // CHECK:STDOUT: %.loc12_13.2: type = assoc_entity_type @GenericInterface.%GenericInterface.type (%GenericInterface.type.2), @GenericInterface.%F.type (%F.type.1) [symbolic = %.loc12_13.2 (constants.%.1)] -// CHECK:STDOUT: %.loc12_13.3: @GenericInterface.%.loc12_13.2 (%.1) = assoc_entity element0, %F.decl [symbolic = %.loc12_13.3 (constants.%.2)] +// CHECK:STDOUT: %.loc12_13.3: @GenericInterface.%.loc12_13.2 (%.1) = assoc_entity %F.decl, element0 [symbolic = %.loc12_13.3 (constants.%.2)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: %Self.1: @GenericInterface.%GenericInterface.type (%GenericInterface.type.2) = bind_symbolic_name Self, 1 [symbolic = %Self.2 (constants.%Self)] @@ -89,7 +89,7 @@ class C { // CHECK:STDOUT: %x.param: @F.1.%T (%T) = value_param runtime_param0 // CHECK:STDOUT: %x: @F.1.%T (%T) = bind_name x, %x.param // CHECK:STDOUT: } -// CHECK:STDOUT: %.loc12_13.1: @GenericInterface.%.loc12_13.2 (%.1) = assoc_entity element0, %F.decl [symbolic = %.loc12_13.3 (constants.%.2)] +// CHECK:STDOUT: %.loc12_13.1: @GenericInterface.%.loc12_13.2 (%.1) = assoc_entity %F.decl, element0 [symbolic = %.loc12_13.3 (constants.%.2)] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self.1 diff --git a/toolchain/check/testdata/impl/fail_impl_as_scope.carbon b/toolchain/check/testdata/impl/fail_impl_as_scope.carbon index ce64d658823af..3a08d8d849b04 100644 --- a/toolchain/check/testdata/impl/fail_impl_as_scope.carbon +++ b/toolchain/check/testdata/impl/fail_impl_as_scope.carbon @@ -27,7 +27,7 @@ impl as Simple { // CHECK:STDOUT: %F.type.1: type = fn_type @F.1 [template] // CHECK:STDOUT: %F.1: %F.type.1 = struct_value () [template] // CHECK:STDOUT: %.1: type = assoc_entity_type %Simple.type, %F.type.1 [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @Simple.%F.decl [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @Simple.%F.decl, element0 [template] // CHECK:STDOUT: %F.type.2: type = fn_type @F.2 [template] // CHECK:STDOUT: %F.2: %F.type.2 = struct_value () [template] // CHECK:STDOUT: %.3: = interface_witness (%F.2) [template] @@ -56,7 +56,7 @@ impl as Simple { // CHECK:STDOUT: interface @Simple { // CHECK:STDOUT: %Self: %Simple.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self] // CHECK:STDOUT: %F.decl: %F.type.1 = fn_decl @F.1 [template = constants.%F.1] {} {} -// CHECK:STDOUT: %.loc12: %.1 = assoc_entity element0, %F.decl [template = constants.%.2] +// CHECK:STDOUT: %.loc12: %.1 = assoc_entity %F.decl, element0 [template = constants.%.2] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self diff --git a/toolchain/check/testdata/impl/fail_impl_bad_assoc_const.carbon b/toolchain/check/testdata/impl/fail_impl_bad_assoc_const.carbon index fe39c10513035..381ba2fb582f2 100644 --- a/toolchain/check/testdata/impl/fail_impl_bad_assoc_const.carbon +++ b/toolchain/check/testdata/impl/fail_impl_bad_assoc_const.carbon @@ -21,7 +21,7 @@ impl bool as I {} // CHECK:STDOUT: %I.type: type = facet_type <@I> [template] // CHECK:STDOUT: %Self: %I.type = bind_symbolic_name Self, 0 [symbolic] // CHECK:STDOUT: %.1: type = assoc_entity_type %I.type, type [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @I.%T [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @I.%T, element0 [template] // CHECK:STDOUT: %Bool.type: type = fn_type @Bool [template] // CHECK:STDOUT: %Bool: %Bool.type = struct_value () [template] // CHECK:STDOUT: } @@ -52,7 +52,7 @@ impl bool as I {} // CHECK:STDOUT: interface @I { // CHECK:STDOUT: %Self: %I.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self] // CHECK:STDOUT: %T: type = assoc_const_decl T [template] -// CHECK:STDOUT: %.loc11: %.1 = assoc_entity element0, %T [template = constants.%.2] +// CHECK:STDOUT: %.loc11: %.1 = assoc_entity %T, element0 [template = constants.%.2] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self diff --git a/toolchain/check/testdata/impl/fail_impl_bad_assoc_fn.carbon b/toolchain/check/testdata/impl/fail_impl_bad_assoc_fn.carbon index 928cea0656383..eedc77acd0353 100644 --- a/toolchain/check/testdata/impl/fail_impl_bad_assoc_fn.carbon +++ b/toolchain/check/testdata/impl/fail_impl_bad_assoc_fn.carbon @@ -221,7 +221,7 @@ class SelfNestedBadReturnType { // CHECK:STDOUT: %F.type.1: type = fn_type @F.1 [template] // CHECK:STDOUT: %F.1: %F.type.1 = struct_value () [template] // CHECK:STDOUT: %.1: type = assoc_entity_type %I.type, %F.type.1 [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @I.%F.decl [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @I.%F.decl, element0 [template] // CHECK:STDOUT: %NoF: type = class_type @NoF [template] // CHECK:STDOUT: %.3: type = struct_type {} [template] // CHECK:STDOUT: %.4: = complete_type_witness %.3 [template] @@ -249,7 +249,7 @@ class SelfNestedBadReturnType { // CHECK:STDOUT: %F.type.5: type = fn_type @F.5 [template] // CHECK:STDOUT: %F.6: %F.type.5 = struct_value () [template] // CHECK:STDOUT: %.8: type = assoc_entity_type %J.type, %F.type.5 [template] -// CHECK:STDOUT: %.9: %.8 = assoc_entity element0, @J.%F.decl [template] +// CHECK:STDOUT: %.9: %.8 = assoc_entity @J.%F.decl, element0 [template] // CHECK:STDOUT: %FMissingParam: type = class_type @FMissingParam [template] // CHECK:STDOUT: %F.type.6: type = fn_type @F.6 [template] // CHECK:STDOUT: %F.7: %F.type.6 = struct_value () [template] @@ -294,7 +294,7 @@ class SelfNestedBadReturnType { // CHECK:STDOUT: %F.type.13: type = fn_type @F.13 [template] // CHECK:STDOUT: %F.14: %F.type.13 = struct_value () [template] // CHECK:STDOUT: %.23: type = assoc_entity_type %SelfNested.type, %F.type.13 [template] -// CHECK:STDOUT: %.24: %.23 = assoc_entity element0, @SelfNested.%F.decl [template] +// CHECK:STDOUT: %.24: %.23 = assoc_entity @SelfNested.%F.decl, element0 [template] // CHECK:STDOUT: %SelfNestedBadParam: type = class_type @SelfNestedBadParam [template] // CHECK:STDOUT: %.25: type = ptr_type %SelfNestedBadParam [template] // CHECK:STDOUT: %.26: type = struct_type {.x: %i32, .y: %i32} [template] @@ -372,7 +372,7 @@ class SelfNestedBadReturnType { // CHECK:STDOUT: interface @I { // CHECK:STDOUT: %Self: %I.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self.1] // CHECK:STDOUT: %F.decl: %F.type.1 = fn_decl @F.1 [template = constants.%F.1] {} {} -// CHECK:STDOUT: %.loc11: %.1 = assoc_entity element0, %F.decl [template = constants.%.2] +// CHECK:STDOUT: %.loc11: %.1 = assoc_entity %F.decl, element0 [template = constants.%.2] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self @@ -406,7 +406,7 @@ class SelfNestedBadReturnType { // CHECK:STDOUT: %return.param: ref bool = out_param runtime_param2 // CHECK:STDOUT: %return: ref bool = return_slot %return.param // CHECK:STDOUT: } -// CHECK:STDOUT: %.loc93: %.8 = assoc_entity element0, %F.decl [template = constants.%.9] +// CHECK:STDOUT: %.loc93: %.8 = assoc_entity %F.decl, element0 [template = constants.%.9] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self @@ -446,7 +446,7 @@ class SelfNestedBadReturnType { // CHECK:STDOUT: %return.param: ref @F.13.%.loc188_52.1 (%.22) = out_param runtime_param1 // CHECK:STDOUT: %return: ref @F.13.%.loc188_52.1 (%.22) = return_slot %return.param // CHECK:STDOUT: } -// CHECK:STDOUT: %.loc188: %.23 = assoc_entity element0, %F.decl [template = constants.%.24] +// CHECK:STDOUT: %.loc188: %.23 = assoc_entity %F.decl, element0 [template = constants.%.24] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self diff --git a/toolchain/check/testdata/impl/fail_self_type_mismatch.carbon b/toolchain/check/testdata/impl/fail_self_type_mismatch.carbon index e4cf2f7985506..1d84ea3f1671b 100644 --- a/toolchain/check/testdata/impl/fail_self_type_mismatch.carbon +++ b/toolchain/check/testdata/impl/fail_self_type_mismatch.carbon @@ -42,7 +42,7 @@ impl i32 as I { // CHECK:STDOUT: %F.type.1: type = fn_type @F.1 [template] // CHECK:STDOUT: %F.1: %F.type.1 = struct_value () [template] // CHECK:STDOUT: %.3: type = assoc_entity_type %I.type, %F.type.1 [template] -// CHECK:STDOUT: %.4: %.3 = assoc_entity element0, @I.%F.decl [template] +// CHECK:STDOUT: %.4: %.3 = assoc_entity @I.%F.decl, element0 [template] // CHECK:STDOUT: %.5: Core.IntLiteral = int_value 32 [template] // CHECK:STDOUT: %Int.type: type = fn_type @Int [template] // CHECK:STDOUT: %Int: %Int.type = struct_value () [template] @@ -103,7 +103,7 @@ impl i32 as I { // CHECK:STDOUT: %c.param: @F.1.%C.loc14_12.1 (%C.3) = value_param runtime_param0 // CHECK:STDOUT: %c: @F.1.%C.loc14_12.1 (%C.3) = bind_name c, %c.param // CHECK:STDOUT: } -// CHECK:STDOUT: %.loc14: %.3 = assoc_entity element0, %F.decl [template = constants.%.4] +// CHECK:STDOUT: %.loc14: %.3 = assoc_entity %F.decl, element0 [template = constants.%.4] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self diff --git a/toolchain/check/testdata/impl/fail_todo_impl_assoc_const.carbon b/toolchain/check/testdata/impl/fail_todo_impl_assoc_const.carbon index a48499d37ef30..8d6a01bd2978c 100644 --- a/toolchain/check/testdata/impl/fail_todo_impl_assoc_const.carbon +++ b/toolchain/check/testdata/impl/fail_todo_impl_assoc_const.carbon @@ -21,7 +21,7 @@ impl bool as I where .T = bool {} // CHECK:STDOUT: %I.type.1: type = facet_type <@I> [template] // CHECK:STDOUT: %Self: %I.type.1 = bind_symbolic_name Self, 0 [symbolic] // CHECK:STDOUT: %.1: type = assoc_entity_type %I.type.1, type [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @I.%T [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @I.%T, element0 [template] // CHECK:STDOUT: %Bool.type: type = fn_type @Bool [template] // CHECK:STDOUT: %Bool: %Bool.type = struct_value () [template] // CHECK:STDOUT: %.Self: %I.type.1 = bind_symbolic_name .Self, 0 [symbolic] @@ -67,7 +67,7 @@ impl bool as I where .T = bool {} // CHECK:STDOUT: interface @I { // CHECK:STDOUT: %Self: %I.type.1 = bind_symbolic_name Self, 0 [symbolic = constants.%Self] // CHECK:STDOUT: %T: type = assoc_const_decl T [template] -// CHECK:STDOUT: %.loc11: %.1 = assoc_entity element0, %T [template = constants.%.2] +// CHECK:STDOUT: %.loc11: %.1 = assoc_entity %T, element0 [template = constants.%.2] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self diff --git a/toolchain/check/testdata/impl/impl_as.carbon b/toolchain/check/testdata/impl/impl_as.carbon index 9bad9ade85501..e6a5444b43c5e 100644 --- a/toolchain/check/testdata/impl/impl_as.carbon +++ b/toolchain/check/testdata/impl/impl_as.carbon @@ -29,7 +29,7 @@ class C { // CHECK:STDOUT: %F.type.1: type = fn_type @F.1 [template] // CHECK:STDOUT: %F.1: %F.type.1 = struct_value () [template] // CHECK:STDOUT: %.1: type = assoc_entity_type %Simple.type, %F.type.1 [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @Simple.%F.decl [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @Simple.%F.decl, element0 [template] // CHECK:STDOUT: %C: type = class_type @C [template] // CHECK:STDOUT: %F.type.2: type = fn_type @F.2 [template] // CHECK:STDOUT: %F.2: %F.type.2 = struct_value () [template] @@ -61,7 +61,7 @@ class C { // CHECK:STDOUT: interface @Simple { // CHECK:STDOUT: %Self: %Simple.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self] // CHECK:STDOUT: %F.decl: %F.type.1 = fn_decl @F.1 [template = constants.%F.1] {} {} -// CHECK:STDOUT: %.loc12: %.1 = assoc_entity element0, %F.decl [template = constants.%.2] +// CHECK:STDOUT: %.loc12: %.1 = assoc_entity %F.decl, element0 [template = constants.%.2] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self diff --git a/toolchain/check/testdata/impl/impl_forall.carbon b/toolchain/check/testdata/impl/impl_forall.carbon index 7db8e3e446d8c..ffd6cd794d458 100644 --- a/toolchain/check/testdata/impl/impl_forall.carbon +++ b/toolchain/check/testdata/impl/impl_forall.carbon @@ -24,7 +24,7 @@ impl forall [T:! type] T as Simple { // CHECK:STDOUT: %F.type.1: type = fn_type @F.1 [template] // CHECK:STDOUT: %F.1: %F.type.1 = struct_value () [template] // CHECK:STDOUT: %.1: type = assoc_entity_type %Simple.type, %F.type.1 [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @Simple.%F.decl [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @Simple.%F.decl, element0 [template] // CHECK:STDOUT: %T: type = bind_symbolic_name T, 0 [symbolic] // CHECK:STDOUT: %T.patt: type = symbolic_binding_pattern T, 0 [symbolic] // CHECK:STDOUT: %F.type.2: type = fn_type @F.2, @impl(%T) [symbolic] @@ -61,7 +61,7 @@ impl forall [T:! type] T as Simple { // CHECK:STDOUT: interface @Simple { // CHECK:STDOUT: %Self: %Simple.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self] // CHECK:STDOUT: %F.decl: %F.type.1 = fn_decl @F.1 [template = constants.%F.1] {} {} -// CHECK:STDOUT: %.loc12: %.1 = assoc_entity element0, %F.decl [template = constants.%.2] +// CHECK:STDOUT: %.loc12: %.1 = assoc_entity %F.decl, element0 [template = constants.%.2] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self diff --git a/toolchain/check/testdata/impl/lookup/alias.carbon b/toolchain/check/testdata/impl/lookup/alias.carbon index 2f8772cbb695f..32330f69bf58f 100644 --- a/toolchain/check/testdata/impl/lookup/alias.carbon +++ b/toolchain/check/testdata/impl/lookup/alias.carbon @@ -34,7 +34,7 @@ fn G(c: C) { // CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [template] // CHECK:STDOUT: %F.1: %F.type.1 = struct_value () [template] // CHECK:STDOUT: %.1: type = assoc_entity_type %HasF.type, %F.type.1 [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @HasF.%F.decl [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @HasF.%F.decl, element0 [template] // CHECK:STDOUT: %C: type = class_type @C [template] // CHECK:STDOUT: %.3: type = struct_type {} [template] // CHECK:STDOUT: %.4: = complete_type_witness %.3 [template] @@ -80,7 +80,7 @@ fn G(c: C) { // CHECK:STDOUT: interface @HasF { // CHECK:STDOUT: %Self: %HasF.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self] // CHECK:STDOUT: %F.decl: %F.type.1 = fn_decl @F.1 [template = constants.%F.1] {} {} -// CHECK:STDOUT: %.loc12: %.1 = assoc_entity element0, %F.decl [template = constants.%.2] +// CHECK:STDOUT: %.loc12: %.1 = assoc_entity %F.decl, element0 [template = constants.%.2] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self diff --git a/toolchain/check/testdata/impl/lookup/fail_alias_impl_not_found.carbon b/toolchain/check/testdata/impl/lookup/fail_alias_impl_not_found.carbon index bf1ba69bd5d4b..ac68823c96164 100644 --- a/toolchain/check/testdata/impl/lookup/fail_alias_impl_not_found.carbon +++ b/toolchain/check/testdata/impl/lookup/fail_alias_impl_not_found.carbon @@ -36,7 +36,7 @@ fn F(c: C) { // CHECK:STDOUT: %F.type.1: type = fn_type @F.1 [template] // CHECK:STDOUT: %F.1: %F.type.1 = struct_value () [template] // CHECK:STDOUT: %.1: type = assoc_entity_type %I.type, %F.type.1 [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @I.%F.decl [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @I.%F.decl, element0 [template] // CHECK:STDOUT: %C: type = class_type @C [template] // CHECK:STDOUT: %.3: type = struct_type {} [template] // CHECK:STDOUT: %.4: = complete_type_witness %.3 [template] @@ -74,7 +74,7 @@ fn F(c: C) { // CHECK:STDOUT: interface @I { // CHECK:STDOUT: %Self: %I.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self] // CHECK:STDOUT: %F.decl: %F.type.1 = fn_decl @F.1 [template = constants.%F.1] {} {} -// CHECK:STDOUT: %.loc12: %.1 = assoc_entity element0, %F.decl [template = constants.%.2] +// CHECK:STDOUT: %.loc12: %.1 = assoc_entity %F.decl, element0 [template = constants.%.2] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self diff --git a/toolchain/check/testdata/impl/lookup/fail_todo_undefined_impl.carbon b/toolchain/check/testdata/impl/lookup/fail_todo_undefined_impl.carbon index 1b796f4d93500..05ff49f1066cd 100644 --- a/toolchain/check/testdata/impl/lookup/fail_todo_undefined_impl.carbon +++ b/toolchain/check/testdata/impl/lookup/fail_todo_undefined_impl.carbon @@ -36,7 +36,7 @@ impl C as I { // CHECK:STDOUT: %F.type.1: type = fn_type @F.1 [template] // CHECK:STDOUT: %F.1: %F.type.1 = struct_value () [template] // CHECK:STDOUT: %.1: type = assoc_entity_type %I.type, %F.type.1 [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @I.%F.decl [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @I.%F.decl, element0 [template] // CHECK:STDOUT: %C: type = class_type @C [template] // CHECK:STDOUT: %.3: type = struct_type {} [template] // CHECK:STDOUT: %.4: = complete_type_witness %.3 [template] @@ -90,7 +90,7 @@ impl C as I { // CHECK:STDOUT: interface @I { // CHECK:STDOUT: %Self: %I.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self] // CHECK:STDOUT: %F.decl: %F.type.1 = fn_decl @F.1 [template = constants.%F.1] {} {} -// CHECK:STDOUT: %.loc12: %.1 = assoc_entity element0, %F.decl [template = constants.%.2] +// CHECK:STDOUT: %.loc12: %.1 = assoc_entity %F.decl, element0 [template = constants.%.2] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self diff --git a/toolchain/check/testdata/impl/lookup/generic.carbon b/toolchain/check/testdata/impl/lookup/generic.carbon index e75fd2a674aaa..e9227cd43389f 100644 --- a/toolchain/check/testdata/impl/lookup/generic.carbon +++ b/toolchain/check/testdata/impl/lookup/generic.carbon @@ -130,7 +130,7 @@ fn G(x: A) { // CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [template] // CHECK:STDOUT: %F.1: %F.type.1 = struct_value () [template] // CHECK:STDOUT: %.1: type = assoc_entity_type %HasF.type, %F.type.1 [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @HasF.%F.decl [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @HasF.%F.decl, element0 [template] // CHECK:STDOUT: %T: type = bind_symbolic_name T, 0 [symbolic] // CHECK:STDOUT: %T.patt: type = symbolic_binding_pattern T, 0 [symbolic] // CHECK:STDOUT: %F.type.2: type = fn_type @F.2, @impl(%T) [symbolic] @@ -184,7 +184,7 @@ fn G(x: A) { // CHECK:STDOUT: interface @HasF { // CHECK:STDOUT: %Self: %HasF.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self] // CHECK:STDOUT: %F.decl: %F.type.1 = fn_decl @F.1 [template = constants.%F.1] {} {} -// CHECK:STDOUT: %.loc5: %.1 = assoc_entity element0, %F.decl [template = constants.%.2] +// CHECK:STDOUT: %.loc5: %.1 = assoc_entity %F.decl, element0 [template = constants.%.2] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self @@ -280,7 +280,7 @@ fn G(x: A) { // CHECK:STDOUT: %F.type.1: type = fn_type @F.1 [template] // CHECK:STDOUT: %F.1: %F.type.1 = struct_value () [template] // CHECK:STDOUT: %.2: type = assoc_entity_type %HasF.type, %F.type.1 [template] -// CHECK:STDOUT: %.3: %.2 = assoc_entity element0, @HasF.%F.decl [template] +// CHECK:STDOUT: %.3: %.2 = assoc_entity @HasF.%F.decl, element0 [template] // CHECK:STDOUT: %T: type = bind_symbolic_name T, 0 [symbolic] // CHECK:STDOUT: %T.patt: type = symbolic_binding_pattern T, 0 [symbolic] // CHECK:STDOUT: %F.type.2: type = fn_type @F.2, @impl(%T) [symbolic] @@ -356,7 +356,7 @@ fn G(x: A) { // CHECK:STDOUT: %return.param: ref @F.1.%.loc5_14.1 (%.1) = out_param runtime_param1 // CHECK:STDOUT: %return: ref @F.1.%.loc5_14.1 (%.1) = return_slot %return.param // CHECK:STDOUT: } -// CHECK:STDOUT: %.loc5: %.2 = assoc_entity element0, %F.decl [template = constants.%.3] +// CHECK:STDOUT: %.loc5: %.2 = assoc_entity %F.decl, element0 [template = constants.%.3] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self @@ -484,7 +484,7 @@ fn G(x: A) { // CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [template] // CHECK:STDOUT: %F.1: %F.type.1 = struct_value () [template] // CHECK:STDOUT: %.1: type = assoc_entity_type %HasF.type, %F.type.1 [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @HasF.%F.decl [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @HasF.%F.decl, element0 [template] // CHECK:STDOUT: %T: type = bind_symbolic_name T, 0 [symbolic] // CHECK:STDOUT: %T.patt: type = symbolic_binding_pattern T, 0 [symbolic] // CHECK:STDOUT: %C.type: type = generic_class_type @C [template] @@ -555,7 +555,7 @@ fn G(x: A) { // CHECK:STDOUT: interface @HasF { // CHECK:STDOUT: %Self: %HasF.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self] // CHECK:STDOUT: %F.decl: %F.type.1 = fn_decl @F.1 [template = constants.%F.1] {} {} -// CHECK:STDOUT: %.loc5: %.1 = assoc_entity element0, %F.decl [template = constants.%.2] +// CHECK:STDOUT: %.loc5: %.1 = assoc_entity %F.decl, element0 [template = constants.%.2] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self @@ -690,7 +690,7 @@ fn G(x: A) { // CHECK:STDOUT: %F.type.1: type = fn_type @F.1, @HasF(%T) [symbolic] // CHECK:STDOUT: %F.1: %F.type.1 = struct_value () [symbolic] // CHECK:STDOUT: %.1: type = assoc_entity_type %HasF.type.2, %F.type.1 [symbolic] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @HasF.%F.decl [symbolic] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @HasF.%F.decl, element0 [symbolic] // CHECK:STDOUT: %.3: type = struct_type {} [template] // CHECK:STDOUT: %F.type.2: type = fn_type @F.2, @impl(%T) [symbolic] // CHECK:STDOUT: %F.2: %F.type.2 = struct_value () [symbolic] @@ -702,7 +702,7 @@ fn G(x: A) { // CHECK:STDOUT: %F.type.3: type = fn_type @F.1, @HasF(%.3) [template] // CHECK:STDOUT: %F.3: %F.type.3 = struct_value () [template] // CHECK:STDOUT: %.6: type = assoc_entity_type %HasF.type.3, %F.type.3 [template] -// CHECK:STDOUT: %.7: %.6 = assoc_entity element0, @HasF.%F.decl [template] +// CHECK:STDOUT: %.7: %.6 = assoc_entity @HasF.%F.decl, element0 [template] // CHECK:STDOUT: %F.type.4: type = fn_type @F.2, @impl(%.3) [template] // CHECK:STDOUT: %F.4: %F.type.4 = struct_value () [template] // CHECK:STDOUT: %.8: = interface_witness (%F.4) [template] @@ -763,12 +763,12 @@ fn G(x: A) { // CHECK:STDOUT: %F.type: type = fn_type @F.1, @HasF(%T.loc4_16.2) [symbolic = %F.type (constants.%F.type.1)] // CHECK:STDOUT: %F: @HasF.%F.type (%F.type.1) = struct_value () [symbolic = %F (constants.%F.1)] // CHECK:STDOUT: %.loc5_9.2: type = assoc_entity_type @HasF.%HasF.type (%HasF.type.2), @HasF.%F.type (%F.type.1) [symbolic = %.loc5_9.2 (constants.%.1)] -// CHECK:STDOUT: %.loc5_9.3: @HasF.%.loc5_9.2 (%.1) = assoc_entity element0, %F.decl [symbolic = %.loc5_9.3 (constants.%.2)] +// CHECK:STDOUT: %.loc5_9.3: @HasF.%.loc5_9.2 (%.1) = assoc_entity %F.decl, element0 [symbolic = %.loc5_9.3 (constants.%.2)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: %Self.1: @HasF.%HasF.type (%HasF.type.2) = bind_symbolic_name Self, 1 [symbolic = %Self.2 (constants.%Self)] // CHECK:STDOUT: %F.decl: @HasF.%F.type (%F.type.1) = fn_decl @F.1 [symbolic = @HasF.%F (constants.%F.1)] {} {} -// CHECK:STDOUT: %.loc5_9.1: @HasF.%.loc5_9.2 (%.1) = assoc_entity element0, %F.decl [symbolic = %.loc5_9.3 (constants.%.2)] +// CHECK:STDOUT: %.loc5_9.1: @HasF.%.loc5_9.2 (%.1) = assoc_entity %F.decl, element0 [symbolic = %.loc5_9.3 (constants.%.2)] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self.1 @@ -908,7 +908,7 @@ fn G(x: A) { // CHECK:STDOUT: %F.type.1: type = fn_type @F.1 [template] // CHECK:STDOUT: %F.1: %F.type.1 = struct_value () [template] // CHECK:STDOUT: %.1: type = assoc_entity_type %HasF.type, %F.type.1 [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @HasF.%F.decl [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @HasF.%F.decl, element0 [template] // CHECK:STDOUT: %T: type = bind_symbolic_name T, 0 [symbolic] // CHECK:STDOUT: %T.patt: type = symbolic_binding_pattern T, 0 [symbolic] // CHECK:STDOUT: %U: type = bind_symbolic_name U, 1 [symbolic] @@ -964,7 +964,7 @@ fn G(x: A) { // CHECK:STDOUT: interface @HasF { // CHECK:STDOUT: %Self: %HasF.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self] // CHECK:STDOUT: %F.decl: %F.type.1 = fn_decl @F.1 [template = constants.%F.1] {} {} -// CHECK:STDOUT: %.loc5: %.1 = assoc_entity element0, %F.decl [template = constants.%.2] +// CHECK:STDOUT: %.loc5: %.1 = assoc_entity %F.decl, element0 [template = constants.%.2] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self @@ -1052,7 +1052,7 @@ fn G(x: A) { // CHECK:STDOUT: %F.type.1: type = fn_type @F.1, @HasF(%T) [symbolic] // CHECK:STDOUT: %F.1: %F.type.1 = struct_value () [symbolic] // CHECK:STDOUT: %.1: type = assoc_entity_type %HasF.type.2, %F.type.1 [symbolic] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @HasF.%F.decl [symbolic] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @HasF.%F.decl, element0 [symbolic] // CHECK:STDOUT: %F.type.2: type = fn_type @F.2, @impl(%T) [symbolic] // CHECK:STDOUT: %F.2: %F.type.2 = struct_value () [symbolic] // CHECK:STDOUT: %.3: %HasF.type.2 = facet_value %T, %T [symbolic] @@ -1067,7 +1067,7 @@ fn G(x: A) { // CHECK:STDOUT: %F.type.3: type = fn_type @F.1, @HasF(%B) [template] // CHECK:STDOUT: %F.3: %F.type.3 = struct_value () [template] // CHECK:STDOUT: %.8: type = assoc_entity_type %HasF.type.3, %F.type.3 [template] -// CHECK:STDOUT: %.9: %.8 = assoc_entity element0, @HasF.%F.decl [template] +// CHECK:STDOUT: %.9: %.8 = assoc_entity @HasF.%F.decl, element0 [template] // CHECK:STDOUT: } // CHECK:STDOUT: // CHECK:STDOUT: imports { @@ -1126,12 +1126,12 @@ fn G(x: A) { // CHECK:STDOUT: %F.type: type = fn_type @F.1, @HasF(%T.loc4_16.2) [symbolic = %F.type (constants.%F.type.1)] // CHECK:STDOUT: %F: @HasF.%F.type (%F.type.1) = struct_value () [symbolic = %F (constants.%F.1)] // CHECK:STDOUT: %.loc5_9.2: type = assoc_entity_type @HasF.%HasF.type (%HasF.type.2), @HasF.%F.type (%F.type.1) [symbolic = %.loc5_9.2 (constants.%.1)] -// CHECK:STDOUT: %.loc5_9.3: @HasF.%.loc5_9.2 (%.1) = assoc_entity element0, %F.decl [symbolic = %.loc5_9.3 (constants.%.2)] +// CHECK:STDOUT: %.loc5_9.3: @HasF.%.loc5_9.2 (%.1) = assoc_entity %F.decl, element0 [symbolic = %.loc5_9.3 (constants.%.2)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: %Self.1: @HasF.%HasF.type (%HasF.type.2) = bind_symbolic_name Self, 1 [symbolic = %Self.2 (constants.%Self)] // CHECK:STDOUT: %F.decl: @HasF.%F.type (%F.type.1) = fn_decl @F.1 [symbolic = @HasF.%F (constants.%F.1)] {} {} -// CHECK:STDOUT: %.loc5_9.1: @HasF.%.loc5_9.2 (%.1) = assoc_entity element0, %F.decl [symbolic = %.loc5_9.3 (constants.%.2)] +// CHECK:STDOUT: %.loc5_9.1: @HasF.%.loc5_9.2 (%.1) = assoc_entity %F.decl, element0 [symbolic = %.loc5_9.3 (constants.%.2)] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self.1 diff --git a/toolchain/check/testdata/impl/lookup/instance_method.carbon b/toolchain/check/testdata/impl/lookup/instance_method.carbon index 54b2ca1e9c45c..21d3369baa8e9 100644 --- a/toolchain/check/testdata/impl/lookup/instance_method.carbon +++ b/toolchain/check/testdata/impl/lookup/instance_method.carbon @@ -38,7 +38,7 @@ fn F(c: C) -> i32 { // CHECK:STDOUT: %F.type.1: type = fn_type @F.1 [template] // CHECK:STDOUT: %F.1: %F.type.1 = struct_value () [template] // CHECK:STDOUT: %.3: type = assoc_entity_type %I.type, %F.type.1 [template] -// CHECK:STDOUT: %.4: %.3 = assoc_entity element0, @I.%F.decl [template] +// CHECK:STDOUT: %.4: %.3 = assoc_entity @I.%F.decl, element0 [template] // CHECK:STDOUT: %F.type.2: type = fn_type @F.2 [template] // CHECK:STDOUT: %F.2: %F.type.2 = struct_value () [template] // CHECK:STDOUT: %.5: %I.type = facet_value %C, %C [template] @@ -106,7 +106,7 @@ fn F(c: C) -> i32 { // CHECK:STDOUT: %return.param: ref %i32 = out_param runtime_param1 // CHECK:STDOUT: %return: ref %i32 = return_slot %return.param // CHECK:STDOUT: } -// CHECK:STDOUT: %.loc14: %.3 = assoc_entity element0, %F.decl [template = constants.%.4] +// CHECK:STDOUT: %.loc14: %.3 = assoc_entity %F.decl, element0 [template = constants.%.4] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self diff --git a/toolchain/check/testdata/impl/lookup/no_prelude/impl_forall.carbon b/toolchain/check/testdata/impl/lookup/no_prelude/impl_forall.carbon index d148c9bae908e..44f691d99f343 100644 --- a/toolchain/check/testdata/impl/lookup/no_prelude/impl_forall.carbon +++ b/toolchain/check/testdata/impl/lookup/no_prelude/impl_forall.carbon @@ -53,7 +53,7 @@ fn TestSpecific(a: A({})) -> {} { // CHECK:STDOUT: %F.type.1: type = fn_type @F.1, @I(%U) [symbolic] // CHECK:STDOUT: %F.1: %F.type.1 = struct_value () [symbolic] // CHECK:STDOUT: %.5: type = assoc_entity_type %I.type.2, %F.type.1 [symbolic] -// CHECK:STDOUT: %.6: %.5 = assoc_entity element0, @I.%F.decl [symbolic] +// CHECK:STDOUT: %.6: %.5 = assoc_entity @I.%F.decl, element0 [symbolic] // CHECK:STDOUT: %V: type = bind_symbolic_name V, 0 [symbolic] // CHECK:STDOUT: %V.patt: type = symbolic_binding_pattern V, 0 [symbolic] // CHECK:STDOUT: %A.3: type = class_type @A, @A(%V) [symbolic] @@ -63,7 +63,7 @@ fn TestSpecific(a: A({})) -> {} { // CHECK:STDOUT: %F.type.3: type = fn_type @F.1, @I(%V) [symbolic] // CHECK:STDOUT: %F.3: %F.type.3 = struct_value () [symbolic] // CHECK:STDOUT: %.7: type = assoc_entity_type %I.type.3, %F.type.3 [symbolic] -// CHECK:STDOUT: %.8: %.7 = assoc_entity element0, @I.%F.decl [symbolic] +// CHECK:STDOUT: %.8: %.7 = assoc_entity @I.%F.decl, element0 [symbolic] // CHECK:STDOUT: %.9: %I.type.2 = facet_value %A.3, %A.3 [symbolic] // CHECK:STDOUT: %.10: = interface_witness (%F.2) [symbolic] // CHECK:STDOUT: %.11: type = unbound_element_type %A.3, %V [symbolic] @@ -81,7 +81,7 @@ fn TestSpecific(a: A({})) -> {} { // CHECK:STDOUT: %F.type.4: type = fn_type @F.1, @I(%W) [symbolic] // CHECK:STDOUT: %F.4: %F.type.4 = struct_value () [symbolic] // CHECK:STDOUT: %.19: type = assoc_entity_type %I.type.4, %F.type.4 [symbolic] -// CHECK:STDOUT: %.20: %.19 = assoc_entity element0, @I.%F.decl [symbolic] +// CHECK:STDOUT: %.20: %.19 = assoc_entity @I.%F.decl, element0 [symbolic] // CHECK:STDOUT: %F.type.5: type = fn_type @F.2, @impl(%W) [symbolic] // CHECK:STDOUT: %F.5: %F.type.5 = struct_value () [symbolic] // CHECK:STDOUT: %.21: = interface_witness (%F.5) [symbolic] @@ -96,7 +96,7 @@ fn TestSpecific(a: A({})) -> {} { // CHECK:STDOUT: %F.type.6: type = fn_type @F.1, @I(%.22) [template] // CHECK:STDOUT: %F.6: %F.type.6 = struct_value () [template] // CHECK:STDOUT: %.28: type = assoc_entity_type %I.type.5, %F.type.6 [template] -// CHECK:STDOUT: %.29: %.28 = assoc_entity element0, @I.%F.decl [template] +// CHECK:STDOUT: %.29: %.28 = assoc_entity @I.%F.decl, element0 [template] // CHECK:STDOUT: %F.type.7: type = fn_type @F.2, @impl(%.22) [template] // CHECK:STDOUT: %F.7: %F.type.7 = struct_value () [template] // CHECK:STDOUT: %.30: = interface_witness (%F.7) [template] @@ -185,7 +185,7 @@ fn TestSpecific(a: A({})) -> {} { // CHECK:STDOUT: %F.type: type = fn_type @F.1, @I(%U.loc6_13.2) [symbolic = %F.type (constants.%F.type.1)] // CHECK:STDOUT: %F: @I.%F.type (%F.type.1) = struct_value () [symbolic = %F (constants.%F.1)] // CHECK:STDOUT: %.loc7_26.2: type = assoc_entity_type @I.%I.type (%I.type.2), @I.%F.type (%F.type.1) [symbolic = %.loc7_26.2 (constants.%.5)] -// CHECK:STDOUT: %.loc7_26.3: @I.%.loc7_26.2 (%.5) = assoc_entity element0, %F.decl [symbolic = %.loc7_26.3 (constants.%.6)] +// CHECK:STDOUT: %.loc7_26.3: @I.%.loc7_26.2 (%.5) = assoc_entity %F.decl, element0 [symbolic = %.loc7_26.3 (constants.%.6)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: %Self.1: @I.%I.type (%I.type.2) = bind_symbolic_name Self, 1 [symbolic = %Self.2 (constants.%Self)] @@ -205,7 +205,7 @@ fn TestSpecific(a: A({})) -> {} { // CHECK:STDOUT: %return.param: ref @F.1.%U (%U) = out_param runtime_param1 // CHECK:STDOUT: %return: ref @F.1.%U (%U) = return_slot %return.param // CHECK:STDOUT: } -// CHECK:STDOUT: %.loc7_26.1: @I.%.loc7_26.2 (%.5) = assoc_entity element0, %F.decl [symbolic = %.loc7_26.3 (constants.%.6)] +// CHECK:STDOUT: %.loc7_26.1: @I.%.loc7_26.2 (%.5) = assoc_entity %F.decl, element0 [symbolic = %.loc7_26.3 (constants.%.6)] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self.1 @@ -303,7 +303,7 @@ fn TestSpecific(a: A({})) -> {} { // CHECK:STDOUT: %I.type.loc17_14.2: type = facet_type <@I, @I(%W.loc16_16.2)> [symbolic = %I.type.loc17_14.2 (constants.%I.type.4)] // CHECK:STDOUT: %F.type.loc17_17: type = fn_type @F.1, @I(%W.loc16_16.2) [symbolic = %F.type.loc17_17 (constants.%F.type.4)] // CHECK:STDOUT: %.loc17_17.2: type = assoc_entity_type @TestGeneric.%I.type.loc17_14.2 (%I.type.4), @TestGeneric.%F.type.loc17_17 (%F.type.4) [symbolic = %.loc17_17.2 (constants.%.19)] -// CHECK:STDOUT: %.loc17_17.3: @TestGeneric.%.loc17_17.2 (%.19) = assoc_entity element0, @I.%F.decl [symbolic = %.loc17_17.3 (constants.%.20)] +// CHECK:STDOUT: %.loc17_17.3: @TestGeneric.%.loc17_17.2 (%.19) = assoc_entity @I.%F.decl, element0 [symbolic = %.loc17_17.3 (constants.%.20)] // CHECK:STDOUT: %F.type.loc17_11: type = fn_type @F.2, @impl(%W.loc16_16.2) [symbolic = %F.type.loc17_11 (constants.%F.type.5)] // CHECK:STDOUT: %F: @TestGeneric.%F.type.loc17_11 (%F.type.5) = struct_value () [symbolic = %F (constants.%F.5)] // CHECK:STDOUT: diff --git a/toolchain/check/testdata/impl/lookup/no_prelude/import.carbon b/toolchain/check/testdata/impl/lookup/no_prelude/import.carbon index 0c94f8c57fa9a..a2506a45bb16f 100644 --- a/toolchain/check/testdata/impl/lookup/no_prelude/import.carbon +++ b/toolchain/check/testdata/impl/lookup/no_prelude/import.carbon @@ -201,7 +201,7 @@ fn Test(c: HasExtraInterfaces.C(type)) { // CHECK:STDOUT: %F.type.1: type = fn_type @F.1 [template] // CHECK:STDOUT: %F.1: %F.type.1 = struct_value () [template] // CHECK:STDOUT: %.1: type = assoc_entity_type %HasF.type, %F.type.1 [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @HasF.%F.decl [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @HasF.%F.decl, element0 [template] // CHECK:STDOUT: %C: type = class_type @C [template] // CHECK:STDOUT: %.3: type = struct_type {} [template] // CHECK:STDOUT: %.4: = complete_type_witness %.3 [template] @@ -227,7 +227,7 @@ fn Test(c: HasExtraInterfaces.C(type)) { // CHECK:STDOUT: interface @HasF { // CHECK:STDOUT: %Self: %HasF.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self] // CHECK:STDOUT: %F.decl: %F.type.1 = fn_decl @F.1 [template = constants.%F.1] {} {} -// CHECK:STDOUT: %.loc5: %.1 = assoc_entity element0, %F.decl [template = constants.%.2] +// CHECK:STDOUT: %.loc5: %.1 = assoc_entity %F.decl, element0 [template = constants.%.2] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self @@ -273,7 +273,7 @@ fn Test(c: HasExtraInterfaces.C(type)) { // CHECK:STDOUT: %G.type.1: type = fn_type @G.1 [template] // CHECK:STDOUT: %G.1: %G.type.1 = struct_value () [template] // CHECK:STDOUT: %.1: type = assoc_entity_type %HasG.type, %G.type.1 [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @HasG.%G.decl [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @HasG.%G.decl, element0 [template] // CHECK:STDOUT: %D: type = class_type @D [template] // CHECK:STDOUT: %.3: type = struct_type {} [template] // CHECK:STDOUT: %.4: = complete_type_witness %.3 [template] @@ -338,7 +338,7 @@ fn Test(c: HasExtraInterfaces.C(type)) { // CHECK:STDOUT: interface @HasG { // CHECK:STDOUT: %Self: %HasG.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self.1] // CHECK:STDOUT: %G.decl: %G.type.1 = fn_decl @G.1 [template = constants.%G.1] {} {} -// CHECK:STDOUT: %.loc7: %.1 = assoc_entity element0, %G.decl [template = constants.%.2] +// CHECK:STDOUT: %.loc7: %.1 = assoc_entity %G.decl, element0 [template = constants.%.2] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self @@ -438,7 +438,7 @@ fn Test(c: HasExtraInterfaces.C(type)) { // CHECK:STDOUT: %Self: %HasF.type = bind_symbolic_name Self, 0 [symbolic] // CHECK:STDOUT: %F.type.1: type = fn_type @F.1 [template] // CHECK:STDOUT: %.4: type = assoc_entity_type %HasF.type, %F.type.1 [template] -// CHECK:STDOUT: %.5: %.4 = assoc_entity element0, imports.%import_ref.7 [template] +// CHECK:STDOUT: %.5: %.4 = assoc_entity imports.%import_ref.7, element0 [template] // CHECK:STDOUT: %F.type.2: type = fn_type @F.2 [template] // CHECK:STDOUT: %F.2: %F.type.2 = struct_value () [template] // CHECK:STDOUT: %.6: = interface_witness (%F.2) [template] @@ -526,7 +526,7 @@ fn Test(c: HasExtraInterfaces.C(type)) { // CHECK:STDOUT: %Self.1: %HasF.type = bind_symbolic_name Self, 0 [symbolic] // CHECK:STDOUT: %F.type.1: type = fn_type @F.1 [template] // CHECK:STDOUT: %.4: type = assoc_entity_type %HasF.type, %F.type.1 [template] -// CHECK:STDOUT: %.5: %.4 = assoc_entity element0, imports.%import_ref.7 [template] +// CHECK:STDOUT: %.5: %.4 = assoc_entity imports.%import_ref.7, element0 [template] // CHECK:STDOUT: %C: type = class_type @C [template] // CHECK:STDOUT: %HasG.type: type = facet_type <@HasG> [template] // CHECK:STDOUT: %F.type.2: type = fn_type @F.2 [template] @@ -661,7 +661,7 @@ fn Test(c: HasExtraInterfaces.C(type)) { // CHECK:STDOUT: %Self.1: %HasG.type = bind_symbolic_name Self, 0 [symbolic] // CHECK:STDOUT: %G.type.1: type = fn_type @G.1 [template] // CHECK:STDOUT: %.4: type = assoc_entity_type %HasG.type, %G.type.1 [template] -// CHECK:STDOUT: %.5: %.4 = assoc_entity element0, imports.%import_ref.7 [template] +// CHECK:STDOUT: %.5: %.4 = assoc_entity imports.%import_ref.7, element0 [template] // CHECK:STDOUT: %HasF.type: type = facet_type <@HasF> [template] // CHECK:STDOUT: %D: type = class_type @D [template] // CHECK:STDOUT: %G.type.2: type = fn_type @G.2 [template] @@ -796,7 +796,7 @@ fn Test(c: HasExtraInterfaces.C(type)) { // CHECK:STDOUT: %Self.1: %HasG.type = bind_symbolic_name Self, 0 [symbolic] // CHECK:STDOUT: %G.type.1: type = fn_type @G.1 [template] // CHECK:STDOUT: %.4: type = assoc_entity_type %HasG.type, %G.type.1 [template] -// CHECK:STDOUT: %.5: %.4 = assoc_entity element0, imports.%import_ref.7 [template] +// CHECK:STDOUT: %.5: %.4 = assoc_entity imports.%import_ref.7, element0 [template] // CHECK:STDOUT: %C: type = class_type @C [template] // CHECK:STDOUT: %HasF.type: type = facet_type <@HasF> [template] // CHECK:STDOUT: %G.type.2: type = fn_type @G.2 [template] @@ -916,7 +916,7 @@ fn Test(c: HasExtraInterfaces.C(type)) { // CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [template] // CHECK:STDOUT: %H.1: %H.type.1 = struct_value () [template] // CHECK:STDOUT: %.1: type = assoc_entity_type %Z.type, %H.type.1 [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @Z.%H.decl [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @Z.%H.decl, element0 [template] // CHECK:STDOUT: %H.type.2: type = fn_type @H.2 [template] // CHECK:STDOUT: %H.2: %H.type.2 = struct_value () [template] // CHECK:STDOUT: %.3: %Z.type = facet_value %empty_tuple.type, %empty_tuple.type [template] @@ -938,7 +938,7 @@ fn Test(c: HasExtraInterfaces.C(type)) { // CHECK:STDOUT: interface @Z { // CHECK:STDOUT: %Self: %Z.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self] // CHECK:STDOUT: %H.decl: %H.type.1 = fn_decl @H.1 [template = constants.%H.1] {} {} -// CHECK:STDOUT: %.loc5: %.1 = assoc_entity element0, %H.decl [template = constants.%.2] +// CHECK:STDOUT: %.loc5: %.1 = assoc_entity %H.decl, element0 [template = constants.%.2] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self @@ -979,7 +979,7 @@ fn Test(c: HasExtraInterfaces.C(type)) { // CHECK:STDOUT: %Self: %Z.type = bind_symbolic_name Self, 0 [symbolic] // CHECK:STDOUT: %H.type.1: type = fn_type @H.1 [template] // CHECK:STDOUT: %.1: type = assoc_entity_type %Z.type, %H.type.1 [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, imports.%import_ref.5 [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity imports.%import_ref.5, element0 [template] // CHECK:STDOUT: %H.type.2: type = fn_type @H.2 [template] // CHECK:STDOUT: %H.2: %H.type.2 = struct_value () [template] // CHECK:STDOUT: %.3: = interface_witness (%H.2) [template] @@ -1057,7 +1057,7 @@ fn Test(c: HasExtraInterfaces.C(type)) { // CHECK:STDOUT: %K.type: type = fn_type @K [template] // CHECK:STDOUT: %K: %K.type = struct_value () [template] // CHECK:STDOUT: %.3: type = assoc_entity_type %Y.type, %K.type [template] -// CHECK:STDOUT: %.4: %.3 = assoc_entity element0, @Y.%K.decl [template] +// CHECK:STDOUT: %.4: %.3 = assoc_entity @Y.%K.decl, element0 [template] // CHECK:STDOUT: } // CHECK:STDOUT: // CHECK:STDOUT: file { @@ -1083,7 +1083,7 @@ fn Test(c: HasExtraInterfaces.C(type)) { // CHECK:STDOUT: interface @Y { // CHECK:STDOUT: %Self: %Y.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self] // CHECK:STDOUT: %K.decl: %K.type = fn_decl @K [template = constants.%K] {} {} -// CHECK:STDOUT: %.loc7: %.3 = assoc_entity element0, %K.decl [template = constants.%.4] +// CHECK:STDOUT: %.loc7: %.3 = assoc_entity %K.decl, element0 [template = constants.%.4] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self @@ -1156,7 +1156,7 @@ fn Test(c: HasExtraInterfaces.C(type)) { // CHECK:STDOUT: %L: %L.type = struct_value () [template] // CHECK:STDOUT: %struct: %AnyParam.3 = struct_value () [template] // CHECK:STDOUT: %.6: type = assoc_entity_type %Y.type, %K.type.2 [template] -// CHECK:STDOUT: %.7: %.6 = assoc_entity element0, imports.%import_ref.7 [template] +// CHECK:STDOUT: %.7: %.6 = assoc_entity imports.%import_ref.7, element0 [template] // CHECK:STDOUT: } // CHECK:STDOUT: // CHECK:STDOUT: imports { @@ -1339,7 +1339,7 @@ fn Test(c: HasExtraInterfaces.C(type)) { // CHECK:STDOUT: %Self.3: %Y.type = bind_symbolic_name Self, 0 [symbolic] // CHECK:STDOUT: %K.type: type = fn_type @K [template] // CHECK:STDOUT: %.4: type = assoc_entity_type %Y.type, %K.type [template] -// CHECK:STDOUT: %.5: %.4 = assoc_entity element0, imports.%import_ref.9 [template] +// CHECK:STDOUT: %.5: %.4 = assoc_entity imports.%import_ref.9, element0 [template] // CHECK:STDOUT: } // CHECK:STDOUT: // CHECK:STDOUT: imports { @@ -1501,7 +1501,7 @@ fn Test(c: HasExtraInterfaces.C(type)) { // CHECK:STDOUT: %F.type.1: type = fn_type @F.1 [template] // CHECK:STDOUT: %F.1: %F.type.1 = struct_value () [template] // CHECK:STDOUT: %.3: type = assoc_entity_type %I.type, %F.type.1 [template] -// CHECK:STDOUT: %.4: %.3 = assoc_entity element0, @I.%F.decl [template] +// CHECK:STDOUT: %.4: %.3 = assoc_entity @I.%F.decl, element0 [template] // CHECK:STDOUT: %tuple.type.1: type = tuple_type (type, type, type, type, type, type, type, type) [template] // CHECK:STDOUT: %tuple.type.2: type = tuple_type (%Extra1.type, %Extra2.type, %Extra3.type, %Extra4.type, %Extra5.type, %Extra6.type, %Extra7.type, %Extra8.type) [template] // CHECK:STDOUT: %C.3: type = class_type @C, @C(%tuple.type.2) [template] @@ -1624,7 +1624,7 @@ fn Test(c: HasExtraInterfaces.C(type)) { // CHECK:STDOUT: interface @I { // CHECK:STDOUT: %Self: %I.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self.9] // CHECK:STDOUT: %F.decl: %F.type.1 = fn_decl @F.1 [template = constants.%F.1] {} {} -// CHECK:STDOUT: %.loc14: %.3 = assoc_entity element0, %F.decl [template = constants.%.4] +// CHECK:STDOUT: %.loc14: %.3 = assoc_entity %F.decl, element0 [template = constants.%.4] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self @@ -1693,7 +1693,7 @@ fn Test(c: HasExtraInterfaces.C(type)) { // CHECK:STDOUT: %Self.1: %I.type = bind_symbolic_name Self, 0 [symbolic] // CHECK:STDOUT: %F.type: type = fn_type @F [template] // CHECK:STDOUT: %.4: type = assoc_entity_type %I.type, %F.type [template] -// CHECK:STDOUT: %.5: %.4 = assoc_entity element0, imports.%import_ref.7 [template] +// CHECK:STDOUT: %.5: %.4 = assoc_entity imports.%import_ref.7, element0 [template] // CHECK:STDOUT: %Extra8.type: type = facet_type <@Extra8> [template] // CHECK:STDOUT: %Extra7.type: type = facet_type <@Extra7> [template] // CHECK:STDOUT: %Extra6.type: type = facet_type <@Extra6> [template] diff --git a/toolchain/check/testdata/impl/multiple_extend.carbon b/toolchain/check/testdata/impl/multiple_extend.carbon index 62544c24cd334..3b6ad89f4cd4d 100644 --- a/toolchain/check/testdata/impl/multiple_extend.carbon +++ b/toolchain/check/testdata/impl/multiple_extend.carbon @@ -168,13 +168,13 @@ fn P(o: O) { // CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [template] // CHECK:STDOUT: %F.1: %F.type.1 = struct_value () [template] // CHECK:STDOUT: %.1: type = assoc_entity_type %HasF.type, %F.type.1 [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @HasF.%F.decl [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @HasF.%F.decl, element0 [template] // CHECK:STDOUT: %HasG.type: type = facet_type <@HasG> [template] // CHECK:STDOUT: %Self.2: %HasG.type = bind_symbolic_name Self, 0 [symbolic] // CHECK:STDOUT: %G.type.1: type = fn_type @G.1 [template] // CHECK:STDOUT: %G.1: %G.type.1 = struct_value () [template] // CHECK:STDOUT: %.3: type = assoc_entity_type %HasG.type, %G.type.1 [template] -// CHECK:STDOUT: %.4: %.3 = assoc_entity element0, @HasG.%G.decl [template] +// CHECK:STDOUT: %.4: %.3 = assoc_entity @HasG.%G.decl, element0 [template] // CHECK:STDOUT: %C: type = class_type @C [template] // CHECK:STDOUT: %F.type.2: type = fn_type @F.2 [template] // CHECK:STDOUT: %F.2: %F.type.2 = struct_value () [template] @@ -222,7 +222,7 @@ fn P(o: O) { // CHECK:STDOUT: interface @HasF { // CHECK:STDOUT: %Self: %HasF.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self.1] // CHECK:STDOUT: %F.decl: %F.type.1 = fn_decl @F.1 [template = constants.%F.1] {} {} -// CHECK:STDOUT: %.loc5: %.1 = assoc_entity element0, %F.decl [template = constants.%.2] +// CHECK:STDOUT: %.loc5: %.1 = assoc_entity %F.decl, element0 [template = constants.%.2] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self @@ -233,7 +233,7 @@ fn P(o: O) { // CHECK:STDOUT: interface @HasG { // CHECK:STDOUT: %Self: %HasG.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self.2] // CHECK:STDOUT: %G.decl: %G.type.1 = fn_decl @G.1 [template = constants.%G.1] {} {} -// CHECK:STDOUT: %.loc9: %.3 = assoc_entity element0, %G.decl [template = constants.%.4] +// CHECK:STDOUT: %.loc9: %.3 = assoc_entity %G.decl, element0 [template = constants.%.4] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self @@ -333,13 +333,13 @@ fn P(o: O) { // CHECK:STDOUT: %A.type.1: type = fn_type @A.1 [template] // CHECK:STDOUT: %A.1: %A.type.1 = struct_value () [template] // CHECK:STDOUT: %.1: type = assoc_entity_type %HasA1.type, %A.type.1 [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @HasA1.%A.decl [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @HasA1.%A.decl, element0 [template] // CHECK:STDOUT: %HasA2.type: type = facet_type <@HasA2> [template] // CHECK:STDOUT: %Self.2: %HasA2.type = bind_symbolic_name Self, 0 [symbolic] // CHECK:STDOUT: %A.type.2: type = fn_type @A.2 [template] // CHECK:STDOUT: %A.2: %A.type.2 = struct_value () [template] // CHECK:STDOUT: %.3: type = assoc_entity_type %HasA2.type, %A.type.2 [template] -// CHECK:STDOUT: %.4: %.3 = assoc_entity element0, @HasA2.%A.decl [template] +// CHECK:STDOUT: %.4: %.3 = assoc_entity @HasA2.%A.decl, element0 [template] // CHECK:STDOUT: %D: type = class_type @D [template] // CHECK:STDOUT: %A.type.3: type = fn_type @A.3 [template] // CHECK:STDOUT: %A.3: %A.type.3 = struct_value () [template] @@ -387,7 +387,7 @@ fn P(o: O) { // CHECK:STDOUT: interface @HasA1 { // CHECK:STDOUT: %Self: %HasA1.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self.1] // CHECK:STDOUT: %A.decl: %A.type.1 = fn_decl @A.1 [template = constants.%A.1] {} {} -// CHECK:STDOUT: %.loc5: %.1 = assoc_entity element0, %A.decl [template = constants.%.2] +// CHECK:STDOUT: %.loc5: %.1 = assoc_entity %A.decl, element0 [template = constants.%.2] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self @@ -398,7 +398,7 @@ fn P(o: O) { // CHECK:STDOUT: interface @HasA2 { // CHECK:STDOUT: %Self: %HasA2.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self.2] // CHECK:STDOUT: %A.decl: %A.type.2 = fn_decl @A.2 [template = constants.%A.2] {} {} -// CHECK:STDOUT: %.loc9: %.3 = assoc_entity element0, %A.decl [template = constants.%.4] +// CHECK:STDOUT: %.loc9: %.3 = assoc_entity %A.decl, element0 [template = constants.%.4] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self @@ -487,7 +487,7 @@ fn P(o: O) { // CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [template] // CHECK:STDOUT: %I.1: %I.type.1 = struct_value () [template] // CHECK:STDOUT: %.1: type = assoc_entity_type %HasI.type, %I.type.1 [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @HasI.%I.decl [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @HasI.%I.decl, element0 [template] // CHECK:STDOUT: %B: type = class_type @B [template] // CHECK:STDOUT: %J.type: type = fn_type @J [template] // CHECK:STDOUT: %J: %J.type = struct_value () [template] @@ -537,7 +537,7 @@ fn P(o: O) { // CHECK:STDOUT: interface @HasI { // CHECK:STDOUT: %Self: %HasI.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self] // CHECK:STDOUT: %I.decl: %I.type.1 = fn_decl @I.1 [template = constants.%I.1] {} {} -// CHECK:STDOUT: %.loc5: %.1 = assoc_entity element0, %I.decl [template = constants.%.2] +// CHECK:STDOUT: %.loc5: %.1 = assoc_entity %I.decl, element0 [template = constants.%.2] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self @@ -630,7 +630,7 @@ fn P(o: O) { // CHECK:STDOUT: %K.type.2: type = fn_type @K.2 [template] // CHECK:STDOUT: %K.2: %K.type.2 = struct_value () [template] // CHECK:STDOUT: %.3: type = assoc_entity_type %HasK.type, %K.type.2 [template] -// CHECK:STDOUT: %.4: %.3 = assoc_entity element0, @HasK.%K.decl [template] +// CHECK:STDOUT: %.4: %.3 = assoc_entity @HasK.%K.decl, element0 [template] // CHECK:STDOUT: %L: type = class_type @L [template] // CHECK:STDOUT: %.6: type = unbound_element_type %L, %Base [template] // CHECK:STDOUT: %K.type.3: type = fn_type @K.3 [template] @@ -675,7 +675,7 @@ fn P(o: O) { // CHECK:STDOUT: interface @HasK { // CHECK:STDOUT: %Self: %HasK.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self] // CHECK:STDOUT: %K.decl: %K.type.2 = fn_decl @K.2 [template = constants.%K.2] {} {} -// CHECK:STDOUT: %.loc9: %.3 = assoc_entity element0, %K.decl [template = constants.%.4] +// CHECK:STDOUT: %.loc9: %.3 = assoc_entity %K.decl, element0 [template = constants.%.4] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self @@ -759,13 +759,13 @@ fn P(o: O) { // CHECK:STDOUT: %N.type.2: type = fn_type @N.2 [template] // CHECK:STDOUT: %N.2: %N.type.2 = struct_value () [template] // CHECK:STDOUT: %.3: type = assoc_entity_type %HasN1.type, %N.type.2 [template] -// CHECK:STDOUT: %.4: %.3 = assoc_entity element0, @HasN1.%N.decl [template] +// CHECK:STDOUT: %.4: %.3 = assoc_entity @HasN1.%N.decl, element0 [template] // CHECK:STDOUT: %HasN2.type: type = facet_type <@HasN2> [template] // CHECK:STDOUT: %Self.2: %HasN2.type = bind_symbolic_name Self, 0 [symbolic] // CHECK:STDOUT: %N.type.3: type = fn_type @N.3 [template] // CHECK:STDOUT: %N.3: %N.type.3 = struct_value () [template] // CHECK:STDOUT: %.5: type = assoc_entity_type %HasN2.type, %N.type.3 [template] -// CHECK:STDOUT: %.6: %.5 = assoc_entity element0, @HasN2.%N.decl [template] +// CHECK:STDOUT: %.6: %.5 = assoc_entity @HasN2.%N.decl, element0 [template] // CHECK:STDOUT: %O: type = class_type @O [template] // CHECK:STDOUT: %.8: type = unbound_element_type %O, %NBase [template] // CHECK:STDOUT: %N.type.4: type = fn_type @N.4 [template] @@ -818,7 +818,7 @@ fn P(o: O) { // CHECK:STDOUT: interface @HasN1 { // CHECK:STDOUT: %Self: %HasN1.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self.1] // CHECK:STDOUT: %N.decl: %N.type.2 = fn_decl @N.2 [template = constants.%N.2] {} {} -// CHECK:STDOUT: %.loc9: %.3 = assoc_entity element0, %N.decl [template = constants.%.4] +// CHECK:STDOUT: %.loc9: %.3 = assoc_entity %N.decl, element0 [template = constants.%.4] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self @@ -829,7 +829,7 @@ fn P(o: O) { // CHECK:STDOUT: interface @HasN2 { // CHECK:STDOUT: %Self: %HasN2.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self.2] // CHECK:STDOUT: %N.decl: %N.type.3 = fn_decl @N.3 [template = constants.%N.3] {} {} -// CHECK:STDOUT: %.loc13: %.5 = assoc_entity element0, %N.decl [template = constants.%.6] +// CHECK:STDOUT: %.loc13: %.5 = assoc_entity %N.decl, element0 [template = constants.%.6] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self diff --git a/toolchain/check/testdata/impl/no_prelude/basic.carbon b/toolchain/check/testdata/impl/no_prelude/basic.carbon index 08478d30b5c5e..11dad3ce6bdc6 100644 --- a/toolchain/check/testdata/impl/no_prelude/basic.carbon +++ b/toolchain/check/testdata/impl/no_prelude/basic.carbon @@ -26,7 +26,7 @@ impl C as Simple { // CHECK:STDOUT: %F.type.1: type = fn_type @F.1 [template] // CHECK:STDOUT: %F.1: %F.type.1 = struct_value () [template] // CHECK:STDOUT: %.1: type = assoc_entity_type %Simple.type, %F.type.1 [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @Simple.%F.decl [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @Simple.%F.decl, element0 [template] // CHECK:STDOUT: %C: type = class_type @C [template] // CHECK:STDOUT: %.3: type = struct_type {} [template] // CHECK:STDOUT: %.4: = complete_type_witness %.3 [template] @@ -52,7 +52,7 @@ impl C as Simple { // CHECK:STDOUT: interface @Simple { // CHECK:STDOUT: %Self: %Simple.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self] // CHECK:STDOUT: %F.decl: %F.type.1 = fn_decl @F.1 [template = constants.%F.1] {} {} -// CHECK:STDOUT: %.loc12: %.1 = assoc_entity element0, %F.decl [template = constants.%.2] +// CHECK:STDOUT: %.loc12: %.1 = assoc_entity %F.decl, element0 [template = constants.%.2] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self diff --git a/toolchain/check/testdata/impl/no_prelude/import_extend_impl.carbon b/toolchain/check/testdata/impl/no_prelude/import_extend_impl.carbon index 35bfe49cf6e33..2765184ec4762 100644 --- a/toolchain/check/testdata/impl/no_prelude/import_extend_impl.carbon +++ b/toolchain/check/testdata/impl/no_prelude/import_extend_impl.carbon @@ -41,7 +41,7 @@ fn G(c: C) { // CHECK:STDOUT: %F.type.1: type = fn_type @F.1 [template] // CHECK:STDOUT: %F.1: %F.type.1 = struct_value () [template] // CHECK:STDOUT: %.1: type = assoc_entity_type %I.type, %F.type.1 [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @I.%F.decl [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @I.%F.decl, element0 [template] // CHECK:STDOUT: %C: type = class_type @C [template] // CHECK:STDOUT: %F.type.2: type = fn_type @F.2 [template] // CHECK:STDOUT: %F.2: %F.type.2 = struct_value () [template] @@ -63,7 +63,7 @@ fn G(c: C) { // CHECK:STDOUT: interface @I { // CHECK:STDOUT: %Self: %I.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self] // CHECK:STDOUT: %F.decl: %F.type.1 = fn_decl @F.1 [template = constants.%F.1] {} {} -// CHECK:STDOUT: %.loc5: %.1 = assoc_entity element0, %F.decl [template = constants.%.2] +// CHECK:STDOUT: %.loc5: %.1 = assoc_entity %F.decl, element0 [template = constants.%.2] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self @@ -117,7 +117,7 @@ fn G(c: C) { // CHECK:STDOUT: %Self: %I.type = bind_symbolic_name Self, 0 [symbolic] // CHECK:STDOUT: %F.type.1: type = fn_type @F.1 [template] // CHECK:STDOUT: %.4: type = assoc_entity_type %I.type, %F.type.1 [template] -// CHECK:STDOUT: %.5: %.4 = assoc_entity element0, imports.%import_ref.8 [template] +// CHECK:STDOUT: %.5: %.4 = assoc_entity imports.%import_ref.8, element0 [template] // CHECK:STDOUT: %F.type.2: type = fn_type @F.2 [template] // CHECK:STDOUT: %F.2: %F.type.2 = struct_value () [template] // CHECK:STDOUT: %.6: = interface_witness (%F.2) [template] diff --git a/toolchain/check/testdata/impl/no_prelude/import_self.carbon b/toolchain/check/testdata/impl/no_prelude/import_self.carbon index 911a4390a2bcb..a59ad4ac83ae1 100644 --- a/toolchain/check/testdata/impl/no_prelude/import_self.carbon +++ b/toolchain/check/testdata/impl/no_prelude/import_self.carbon @@ -39,7 +39,7 @@ fn F(x: (), y: ()) -> () { // CHECK:STDOUT: %Op.type: type = fn_type @Op [template] // CHECK:STDOUT: %Op: %Op.type = struct_value () [template] // CHECK:STDOUT: %.2: type = assoc_entity_type %Add.type, %Op.type [template] -// CHECK:STDOUT: %.3: %.2 = assoc_entity element0, @Add.%Op.decl [template] +// CHECK:STDOUT: %.3: %.2 = assoc_entity @Add.%Op.decl, element0 [template] // CHECK:STDOUT: } // CHECK:STDOUT: // CHECK:STDOUT: file { @@ -75,7 +75,7 @@ fn F(x: (), y: ()) -> () { // CHECK:STDOUT: %return.param: ref @Op.%.loc5_15.1 (%.1) = out_param runtime_param2 // CHECK:STDOUT: %return: ref @Op.%.loc5_15.1 (%.1) = return_slot %return.param // CHECK:STDOUT: } -// CHECK:STDOUT: %.loc5: %.2 = assoc_entity element0, %Op.decl [template = constants.%.3] +// CHECK:STDOUT: %.loc5: %.2 = assoc_entity %Op.decl, element0 [template = constants.%.3] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self @@ -112,7 +112,7 @@ fn F(x: (), y: ()) -> () { // CHECK:STDOUT: %F.type: type = fn_type @F [template] // CHECK:STDOUT: %F: %F.type = struct_value () [template] // CHECK:STDOUT: %.4: type = assoc_entity_type %Add.type, %Op.type.2 [template] -// CHECK:STDOUT: %.5: %.4 = assoc_entity element0, imports.%import_ref.5 [template] +// CHECK:STDOUT: %.5: %.4 = assoc_entity imports.%import_ref.5, element0 [template] // CHECK:STDOUT: } // CHECK:STDOUT: // CHECK:STDOUT: imports { diff --git a/toolchain/check/testdata/impl/no_prelude/import_use_generic.carbon b/toolchain/check/testdata/impl/no_prelude/import_use_generic.carbon index ba615cb3efc3c..90587e4a91a72 100644 --- a/toolchain/check/testdata/impl/no_prelude/import_use_generic.carbon +++ b/toolchain/check/testdata/impl/no_prelude/import_use_generic.carbon @@ -54,7 +54,7 @@ fn F() -> c.(I.F)() {} // CHECK:STDOUT: %F.type.1: type = fn_type @F.1 [template] // CHECK:STDOUT: %F.1: %F.type.1 = struct_value () [template] // CHECK:STDOUT: %.3: type = assoc_entity_type %I.type, %F.type.1 [template] -// CHECK:STDOUT: %.4: %.3 = assoc_entity element0, @I.%F.decl [template] +// CHECK:STDOUT: %.4: %.3 = assoc_entity @I.%F.decl, element0 [template] // CHECK:STDOUT: %F.type.2: type = fn_type @F.2, @impl(%T) [symbolic] // CHECK:STDOUT: %F.2: %F.type.2 = struct_value () [symbolic] // CHECK:STDOUT: %.5: %I.type = facet_value %C.2, %C.2 [symbolic] @@ -90,7 +90,7 @@ fn F() -> c.(I.F)() {} // CHECK:STDOUT: interface @I { // CHECK:STDOUT: %Self: %I.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self] // CHECK:STDOUT: %F.decl: %F.type.1 = fn_decl @F.1 [template = constants.%F.1] {} {} -// CHECK:STDOUT: %.loc7: %.3 = assoc_entity element0, %F.decl [template = constants.%.4] +// CHECK:STDOUT: %.loc7: %.3 = assoc_entity %F.decl, element0 [template = constants.%.4] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self @@ -195,7 +195,7 @@ fn F() -> c.(I.F)() {} // CHECK:STDOUT: %Self: %I.type = bind_symbolic_name Self, 0 [symbolic] // CHECK:STDOUT: %F.type.1: type = fn_type @F.1 [template] // CHECK:STDOUT: %.4: type = assoc_entity_type %I.type, %F.type.1 [template] -// CHECK:STDOUT: %.5: %.4 = assoc_entity element0, imports.%import_ref.7 [template] +// CHECK:STDOUT: %.5: %.4 = assoc_entity imports.%import_ref.7, element0 [template] // CHECK:STDOUT: %F.type.2: type = fn_type @F.2, @impl(%T) [symbolic] // CHECK:STDOUT: %F.2: %F.type.2 = struct_value () [symbolic] // CHECK:STDOUT: %.6: = interface_witness (%F.2) [symbolic] diff --git a/toolchain/check/testdata/impl/no_prelude/interface_args.carbon b/toolchain/check/testdata/impl/no_prelude/interface_args.carbon index 54a2d55613ee7..518b5cde2df34 100644 --- a/toolchain/check/testdata/impl/no_prelude/interface_args.carbon +++ b/toolchain/check/testdata/impl/no_prelude/interface_args.carbon @@ -91,7 +91,7 @@ fn MakeC(a: A) -> C { // CHECK:STDOUT: %Op.type.1: type = fn_type @Op.1, @Action(%T) [symbolic] // CHECK:STDOUT: %Op.1: %Op.type.1 = struct_value () [symbolic] // CHECK:STDOUT: %.1: type = assoc_entity_type %Action.type.2, %Op.type.1 [symbolic] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @Action.%Op.decl [symbolic] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @Action.%Op.decl, element0 [symbolic] // CHECK:STDOUT: %A: type = class_type @A [template] // CHECK:STDOUT: %.3: type = struct_type {} [template] // CHECK:STDOUT: %.4: = complete_type_witness %.3 [template] @@ -103,7 +103,7 @@ fn MakeC(a: A) -> C { // CHECK:STDOUT: %Op.type.3: type = fn_type @Op.1, @Action(%B) [template] // CHECK:STDOUT: %Op.3: %Op.type.3 = struct_value () [template] // CHECK:STDOUT: %.5: type = assoc_entity_type %Action.type.3, %Op.type.3 [template] -// CHECK:STDOUT: %.6: %.5 = assoc_entity element0, @Action.%Op.decl [template] +// CHECK:STDOUT: %.6: %.5 = assoc_entity @Action.%Op.decl, element0 [template] // CHECK:STDOUT: %.7: %Action.type.2 = facet_value %A, %A [symbolic] // CHECK:STDOUT: %.8: = interface_witness (%Op.2) [template] // CHECK:STDOUT: %F.type: type = fn_type @F [template] @@ -154,12 +154,12 @@ fn MakeC(a: A) -> C { // CHECK:STDOUT: %Op.type: type = fn_type @Op.1, @Action(%T.loc4_18.2) [symbolic = %Op.type (constants.%Op.type.1)] // CHECK:STDOUT: %Op: @Action.%Op.type (%Op.type.1) = struct_value () [symbolic = %Op (constants.%Op.1)] // CHECK:STDOUT: %.loc5_10.2: type = assoc_entity_type @Action.%Action.type (%Action.type.2), @Action.%Op.type (%Op.type.1) [symbolic = %.loc5_10.2 (constants.%.1)] -// CHECK:STDOUT: %.loc5_10.3: @Action.%.loc5_10.2 (%.1) = assoc_entity element0, %Op.decl [symbolic = %.loc5_10.3 (constants.%.2)] +// CHECK:STDOUT: %.loc5_10.3: @Action.%.loc5_10.2 (%.1) = assoc_entity %Op.decl, element0 [symbolic = %.loc5_10.3 (constants.%.2)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: %Self.1: @Action.%Action.type (%Action.type.2) = bind_symbolic_name Self, 1 [symbolic = %Self.2 (constants.%Self)] // CHECK:STDOUT: %Op.decl: @Action.%Op.type (%Op.type.1) = fn_decl @Op.1 [symbolic = @Action.%Op (constants.%Op.1)] {} {} -// CHECK:STDOUT: %.loc5_10.1: @Action.%.loc5_10.2 (%.1) = assoc_entity element0, %Op.decl [symbolic = %.loc5_10.3 (constants.%.2)] +// CHECK:STDOUT: %.loc5_10.1: @Action.%.loc5_10.2 (%.1) = assoc_entity %Op.decl, element0 [symbolic = %.loc5_10.3 (constants.%.2)] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self.1 @@ -265,14 +265,14 @@ fn MakeC(a: A) -> C { // CHECK:STDOUT: %Op.type.1: type = fn_type @Op.1, @Action(%T) [symbolic] // CHECK:STDOUT: %Op.1: %Op.type.1 = struct_value () [symbolic] // CHECK:STDOUT: %.3: type = assoc_entity_type %Action.type.2, %Op.type.1 [symbolic] -// CHECK:STDOUT: %.4: %.3 = assoc_entity element0, imports.%import_ref.15 [symbolic] +// CHECK:STDOUT: %.4: %.3 = assoc_entity imports.%import_ref.15, element0 [symbolic] // CHECK:STDOUT: %Op.type.2: type = fn_type @Op.1, @Action(%B) [template] // CHECK:STDOUT: %Op.2: %Op.type.2 = struct_value () [template] // CHECK:STDOUT: %.5: type = assoc_entity_type %Action.type.3, %Op.type.2 [template] -// CHECK:STDOUT: %.6: %.5 = assoc_entity element0, imports.%import_ref.16 [template] +// CHECK:STDOUT: %.6: %.5 = assoc_entity imports.%import_ref.16, element0 [template] // CHECK:STDOUT: %G.type: type = fn_type @G [template] // CHECK:STDOUT: %G: %G.type = struct_value () [template] -// CHECK:STDOUT: %.8: %.3 = assoc_entity element0, imports.%import_ref.17 [symbolic] +// CHECK:STDOUT: %.8: %.3 = assoc_entity imports.%import_ref.17, element0 [symbolic] // CHECK:STDOUT: %Op.type.3: type = fn_type @Op.2 [template] // CHECK:STDOUT: %Op.3: %Op.type.3 = struct_value () [template] // CHECK:STDOUT: %.9: = interface_witness (%Op.3) [template] @@ -327,7 +327,7 @@ fn MakeC(a: A) -> C { // CHECK:STDOUT: %Op.type: type = fn_type @Op.1, @Action(%T) [symbolic = %Op.type (constants.%Op.type.1)] // CHECK:STDOUT: %Op: @Action.%Op.type (%Op.type.1) = struct_value () [symbolic = %Op (constants.%Op.1)] // CHECK:STDOUT: %.1: type = assoc_entity_type @Action.%Action.type (%Action.type.2), @Action.%Op.type (%Op.type.1) [symbolic = %.1 (constants.%.3)] -// CHECK:STDOUT: %.2: @Action.%.1 (%.3) = assoc_entity element0, imports.%import_ref.15 [symbolic = %.2 (constants.%.4)] +// CHECK:STDOUT: %.2: @Action.%.1 (%.3) = assoc_entity imports.%import_ref.15, element0 [symbolic = %.2 (constants.%.4)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: !members: @@ -414,11 +414,11 @@ fn MakeC(a: A) -> C { // CHECK:STDOUT: %Op.type.1: type = fn_type @Op, @Action(%T) [symbolic] // CHECK:STDOUT: %Op.1: %Op.type.1 = struct_value () [symbolic] // CHECK:STDOUT: %.3: type = assoc_entity_type %Action.type.2, %Op.type.1 [symbolic] -// CHECK:STDOUT: %.4: %.3 = assoc_entity element0, imports.%import_ref.15 [symbolic] +// CHECK:STDOUT: %.4: %.3 = assoc_entity imports.%import_ref.15, element0 [symbolic] // CHECK:STDOUT: %Op.type.2: type = fn_type @Op, @Action(%B) [template] // CHECK:STDOUT: %Op.2: %Op.type.2 = struct_value () [template] // CHECK:STDOUT: %.5: type = assoc_entity_type %Action.type.3, %Op.type.2 [template] -// CHECK:STDOUT: %.6: %.5 = assoc_entity element0, imports.%import_ref.16 [template] +// CHECK:STDOUT: %.6: %.5 = assoc_entity imports.%import_ref.16, element0 [template] // CHECK:STDOUT: %G.type: type = fn_type @G [template] // CHECK:STDOUT: %G: %G.type = struct_value () [template] // CHECK:STDOUT: %C: type = class_type @C [template] @@ -426,8 +426,8 @@ fn MakeC(a: A) -> C { // CHECK:STDOUT: %Op.type.3: type = fn_type @Op, @Action(%C) [template] // CHECK:STDOUT: %Op.3: %Op.type.3 = struct_value () [template] // CHECK:STDOUT: %.8: type = assoc_entity_type %Action.type.4, %Op.type.3 [template] -// CHECK:STDOUT: %.9: %.8 = assoc_entity element0, imports.%import_ref.15 [template] -// CHECK:STDOUT: %.10: %.3 = assoc_entity element0, imports.%import_ref.18 [symbolic] +// CHECK:STDOUT: %.9: %.8 = assoc_entity imports.%import_ref.15, element0 [template] +// CHECK:STDOUT: %.10: %.3 = assoc_entity imports.%import_ref.18, element0 [symbolic] // CHECK:STDOUT: } // CHECK:STDOUT: // CHECK:STDOUT: imports { @@ -480,7 +480,7 @@ fn MakeC(a: A) -> C { // CHECK:STDOUT: %Op.type: type = fn_type @Op, @Action(%T) [symbolic = %Op.type (constants.%Op.type.1)] // CHECK:STDOUT: %Op: @Action.%Op.type (%Op.type.1) = struct_value () [symbolic = %Op (constants.%Op.1)] // CHECK:STDOUT: %.1: type = assoc_entity_type @Action.%Action.type (%Action.type.2), @Action.%Op.type (%Op.type.1) [symbolic = %.1 (constants.%.3)] -// CHECK:STDOUT: %.2: @Action.%.1 (%.3) = assoc_entity element0, imports.%import_ref.15 [symbolic = %.2 (constants.%.4)] +// CHECK:STDOUT: %.2: @Action.%.1 (%.3) = assoc_entity imports.%import_ref.15, element0 [symbolic = %.2 (constants.%.4)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: !members: @@ -577,7 +577,7 @@ fn MakeC(a: A) -> C { // CHECK:STDOUT: %Make.type.1: type = fn_type @Make.1, @Factory(%T) [symbolic] // CHECK:STDOUT: %Make.1: %Make.type.1 = struct_value () [symbolic] // CHECK:STDOUT: %.1: type = assoc_entity_type %Factory.type.2, %Make.type.1 [symbolic] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @Factory.%Make.decl [symbolic] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @Factory.%Make.decl, element0 [symbolic] // CHECK:STDOUT: %A: type = class_type @A [template] // CHECK:STDOUT: %.3: type = struct_type {} [template] // CHECK:STDOUT: %.4: = complete_type_witness %.3 [template] @@ -588,7 +588,7 @@ fn MakeC(a: A) -> C { // CHECK:STDOUT: %Make.type.3: type = fn_type @Make.1, @Factory(%B) [template] // CHECK:STDOUT: %Make.3: %Make.type.3 = struct_value () [template] // CHECK:STDOUT: %.5: type = assoc_entity_type %Factory.type.3, %Make.type.3 [template] -// CHECK:STDOUT: %.6: %.5 = assoc_entity element0, @Factory.%Make.decl [template] +// CHECK:STDOUT: %.6: %.5 = assoc_entity @Factory.%Make.decl, element0 [template] // CHECK:STDOUT: %.7: %Factory.type.2 = facet_value %A, %A [symbolic] // CHECK:STDOUT: %.8: = interface_witness (%Make.2) [template] // CHECK:STDOUT: } @@ -626,7 +626,7 @@ fn MakeC(a: A) -> C { // CHECK:STDOUT: %Make.type: type = fn_type @Make.1, @Factory(%T.loc4_19.2) [symbolic = %Make.type (constants.%Make.type.1)] // CHECK:STDOUT: %Make: @Factory.%Make.type (%Make.type.1) = struct_value () [symbolic = %Make (constants.%Make.1)] // CHECK:STDOUT: %.loc5_17.2: type = assoc_entity_type @Factory.%Factory.type (%Factory.type.2), @Factory.%Make.type (%Make.type.1) [symbolic = %.loc5_17.2 (constants.%.1)] -// CHECK:STDOUT: %.loc5_17.3: @Factory.%.loc5_17.2 (%.1) = assoc_entity element0, %Make.decl [symbolic = %.loc5_17.3 (constants.%.2)] +// CHECK:STDOUT: %.loc5_17.3: @Factory.%.loc5_17.2 (%.1) = assoc_entity %Make.decl, element0 [symbolic = %.loc5_17.3 (constants.%.2)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: %Self.1: @Factory.%Factory.type (%Factory.type.2) = bind_symbolic_name Self, 1 [symbolic = %Self.2 (constants.%Self)] @@ -638,7 +638,7 @@ fn MakeC(a: A) -> C { // CHECK:STDOUT: %return.param: ref @Make.1.%T (%T) = out_param runtime_param0 // CHECK:STDOUT: %return: ref @Make.1.%T (%T) = return_slot %return.param // CHECK:STDOUT: } -// CHECK:STDOUT: %.loc5_17.1: @Factory.%.loc5_17.2 (%.1) = assoc_entity element0, %Make.decl [symbolic = %.loc5_17.3 (constants.%.2)] +// CHECK:STDOUT: %.loc5_17.1: @Factory.%.loc5_17.2 (%.1) = assoc_entity %Make.decl, element0 [symbolic = %.loc5_17.3 (constants.%.2)] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self.1 @@ -732,14 +732,14 @@ fn MakeC(a: A) -> C { // CHECK:STDOUT: %Make.type.1: type = fn_type @Make.1, @Factory(%T) [symbolic] // CHECK:STDOUT: %Make.1: %Make.type.1 = struct_value () [symbolic] // CHECK:STDOUT: %.3: type = assoc_entity_type %Factory.type.2, %Make.type.1 [symbolic] -// CHECK:STDOUT: %.4: %.3 = assoc_entity element0, imports.%import_ref.13 [symbolic] +// CHECK:STDOUT: %.4: %.3 = assoc_entity imports.%import_ref.13, element0 [symbolic] // CHECK:STDOUT: %Make.type.2: type = fn_type @Make.1, @Factory(%B) [template] // CHECK:STDOUT: %Make.2: %Make.type.2 = struct_value () [template] // CHECK:STDOUT: %.5: type = assoc_entity_type %Factory.type.3, %Make.type.2 [template] -// CHECK:STDOUT: %.6: %.5 = assoc_entity element0, imports.%import_ref.14 [template] +// CHECK:STDOUT: %.6: %.5 = assoc_entity imports.%import_ref.14, element0 [template] // CHECK:STDOUT: %MakeB.type: type = fn_type @MakeB [template] // CHECK:STDOUT: %MakeB: %MakeB.type = struct_value () [template] -// CHECK:STDOUT: %.8: %.3 = assoc_entity element0, imports.%import_ref.15 [symbolic] +// CHECK:STDOUT: %.8: %.3 = assoc_entity imports.%import_ref.15, element0 [symbolic] // CHECK:STDOUT: %Make.type.3: type = fn_type @Make.2 [template] // CHECK:STDOUT: %Make.3: %Make.type.3 = struct_value () [template] // CHECK:STDOUT: %.9: = interface_witness (%Make.3) [template] @@ -795,7 +795,7 @@ fn MakeC(a: A) -> C { // CHECK:STDOUT: %Make.type: type = fn_type @Make.1, @Factory(%T) [symbolic = %Make.type (constants.%Make.type.1)] // CHECK:STDOUT: %Make: @Factory.%Make.type (%Make.type.1) = struct_value () [symbolic = %Make (constants.%Make.1)] // CHECK:STDOUT: %.1: type = assoc_entity_type @Factory.%Factory.type (%Factory.type.2), @Factory.%Make.type (%Make.type.1) [symbolic = %.1 (constants.%.3)] -// CHECK:STDOUT: %.2: @Factory.%.1 (%.3) = assoc_entity element0, imports.%import_ref.13 [symbolic = %.2 (constants.%.4)] +// CHECK:STDOUT: %.2: @Factory.%.1 (%.3) = assoc_entity imports.%import_ref.13, element0 [symbolic = %.2 (constants.%.4)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: !members: @@ -888,11 +888,11 @@ fn MakeC(a: A) -> C { // CHECK:STDOUT: %Make.type.1: type = fn_type @Make, @Factory(%T) [symbolic] // CHECK:STDOUT: %Make.1: %Make.type.1 = struct_value () [symbolic] // CHECK:STDOUT: %.3: type = assoc_entity_type %Factory.type.2, %Make.type.1 [symbolic] -// CHECK:STDOUT: %.4: %.3 = assoc_entity element0, imports.%import_ref.13 [symbolic] +// CHECK:STDOUT: %.4: %.3 = assoc_entity imports.%import_ref.13, element0 [symbolic] // CHECK:STDOUT: %Make.type.2: type = fn_type @Make, @Factory(%B) [template] // CHECK:STDOUT: %Make.2: %Make.type.2 = struct_value () [template] // CHECK:STDOUT: %.5: type = assoc_entity_type %Factory.type.3, %Make.type.2 [template] -// CHECK:STDOUT: %.6: %.5 = assoc_entity element0, imports.%import_ref.14 [template] +// CHECK:STDOUT: %.6: %.5 = assoc_entity imports.%import_ref.14, element0 [template] // CHECK:STDOUT: %C: type = class_type @C [template] // CHECK:STDOUT: %MakeC.type: type = fn_type @MakeC [template] // CHECK:STDOUT: %MakeC: %MakeC.type = struct_value () [template] @@ -900,8 +900,8 @@ fn MakeC(a: A) -> C { // CHECK:STDOUT: %Make.type.3: type = fn_type @Make, @Factory(%C) [template] // CHECK:STDOUT: %Make.3: %Make.type.3 = struct_value () [template] // CHECK:STDOUT: %.8: type = assoc_entity_type %Factory.type.4, %Make.type.3 [template] -// CHECK:STDOUT: %.9: %.8 = assoc_entity element0, imports.%import_ref.13 [template] -// CHECK:STDOUT: %.10: %.3 = assoc_entity element0, imports.%import_ref.15 [symbolic] +// CHECK:STDOUT: %.9: %.8 = assoc_entity imports.%import_ref.13, element0 [template] +// CHECK:STDOUT: %.10: %.3 = assoc_entity imports.%import_ref.15, element0 [symbolic] // CHECK:STDOUT: } // CHECK:STDOUT: // CHECK:STDOUT: imports { @@ -956,7 +956,7 @@ fn MakeC(a: A) -> C { // CHECK:STDOUT: %Make.type: type = fn_type @Make, @Factory(%T) [symbolic = %Make.type (constants.%Make.type.1)] // CHECK:STDOUT: %Make: @Factory.%Make.type (%Make.type.1) = struct_value () [symbolic = %Make (constants.%Make.1)] // CHECK:STDOUT: %.1: type = assoc_entity_type @Factory.%Factory.type (%Factory.type.2), @Factory.%Make.type (%Make.type.1) [symbolic = %.1 (constants.%.3)] -// CHECK:STDOUT: %.2: @Factory.%.1 (%.3) = assoc_entity element0, imports.%import_ref.13 [symbolic = %.2 (constants.%.4)] +// CHECK:STDOUT: %.2: @Factory.%.1 (%.3) = assoc_entity imports.%import_ref.13, element0 [symbolic = %.2 (constants.%.4)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: !members: diff --git a/toolchain/check/testdata/impl/no_prelude/self_in_class.carbon b/toolchain/check/testdata/impl/no_prelude/self_in_class.carbon index d60b7ab1048ae..9932f83f0e344 100644 --- a/toolchain/check/testdata/impl/no_prelude/self_in_class.carbon +++ b/toolchain/check/testdata/impl/no_prelude/self_in_class.carbon @@ -31,7 +31,7 @@ class A { // CHECK:STDOUT: %Make.type.1: type = fn_type @Make.1 [template] // CHECK:STDOUT: %Make.1: %Make.type.1 = struct_value () [template] // CHECK:STDOUT: %.2: type = assoc_entity_type %DefaultConstructible.type, %Make.type.1 [template] -// CHECK:STDOUT: %.3: %.2 = assoc_entity element0, @DefaultConstructible.%Make.decl [template] +// CHECK:STDOUT: %.3: %.2 = assoc_entity @DefaultConstructible.%Make.decl, element0 [template] // CHECK:STDOUT: %C: type = class_type @C [template] // CHECK:STDOUT: %.4: type = struct_type {} [template] // CHECK:STDOUT: %.5: = complete_type_witness %.4 [template] @@ -66,7 +66,7 @@ class A { // CHECK:STDOUT: %return.param: ref @Make.1.%.loc12_16.1 (%.1) = out_param runtime_param0 // CHECK:STDOUT: %return: ref @Make.1.%.loc12_16.1 (%.1) = return_slot %return.param // CHECK:STDOUT: } -// CHECK:STDOUT: %.loc12: %.2 = assoc_entity element0, %Make.decl [template = constants.%.3] +// CHECK:STDOUT: %.loc12: %.2 = assoc_entity %Make.decl, element0 [template = constants.%.3] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self diff --git a/toolchain/check/testdata/impl/no_prelude/self_in_signature.carbon b/toolchain/check/testdata/impl/no_prelude/self_in_signature.carbon index 87ebbacedc68b..36a21df6f3ef6 100644 --- a/toolchain/check/testdata/impl/no_prelude/self_in_signature.carbon +++ b/toolchain/check/testdata/impl/no_prelude/self_in_signature.carbon @@ -46,7 +46,7 @@ impl D as SelfNested { // CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [template] // CHECK:STDOUT: %F.1: %F.type.1 = struct_value () [template] // CHECK:STDOUT: %.2: type = assoc_entity_type %UseSelf.type, %F.type.1 [template] -// CHECK:STDOUT: %.3: %.2 = assoc_entity element0, @UseSelf.%F.decl [template] +// CHECK:STDOUT: %.3: %.2 = assoc_entity @UseSelf.%F.decl, element0 [template] // CHECK:STDOUT: %C: type = class_type @C [template] // CHECK:STDOUT: %.4: type = struct_type {} [template] // CHECK:STDOUT: %.5: = complete_type_witness %.4 [template] @@ -71,7 +71,7 @@ impl D as SelfNested { // CHECK:STDOUT: %F.type.4: type = fn_type @F.4 [template] // CHECK:STDOUT: %F.4: %F.type.4 = struct_value () [template] // CHECK:STDOUT: %.14: type = assoc_entity_type %SelfNested.type, %F.type.4 [template] -// CHECK:STDOUT: %.15: %.14 = assoc_entity element0, @SelfNested.%F.decl [template] +// CHECK:STDOUT: %.15: %.14 = assoc_entity @SelfNested.%F.decl, element0 [template] // CHECK:STDOUT: %.16: type = ptr_type %C [template] // CHECK:STDOUT: %.17: type = struct_type {.x: %C, .y: %empty_tuple.type} [template] // CHECK:STDOUT: %tuple.type.3: type = tuple_type (%.16, %.17) [template] @@ -143,7 +143,7 @@ impl D as SelfNested { // CHECK:STDOUT: %return.param: ref @F.1.%.loc12_14.1 (%.1) = out_param runtime_param2 // CHECK:STDOUT: %return: ref @F.1.%.loc12_14.1 (%.1) = return_slot %return.param // CHECK:STDOUT: } -// CHECK:STDOUT: %.loc12: %.2 = assoc_entity element0, %F.decl [template = constants.%.3] +// CHECK:STDOUT: %.loc12: %.2 = assoc_entity %F.decl, element0 [template = constants.%.3] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self @@ -172,7 +172,7 @@ impl D as SelfNested { // CHECK:STDOUT: %x.param: @F.4.%tuple.type (%tuple.type.2) = value_param runtime_param0 // CHECK:STDOUT: %x: @F.4.%tuple.type (%tuple.type.2) = bind_name x, %x.param // CHECK:STDOUT: } -// CHECK:STDOUT: %.loc28: %.14 = assoc_entity element0, %F.decl [template = constants.%.15] +// CHECK:STDOUT: %.loc28: %.14 = assoc_entity %F.decl, element0 [template = constants.%.15] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self diff --git a/toolchain/check/testdata/interface/assoc_const.carbon b/toolchain/check/testdata/interface/assoc_const.carbon index eb17190448049..76a3634d4a800 100644 --- a/toolchain/check/testdata/interface/assoc_const.carbon +++ b/toolchain/check/testdata/interface/assoc_const.carbon @@ -19,13 +19,13 @@ interface I { // CHECK:STDOUT: %I.type: type = facet_type <@I> [template] // CHECK:STDOUT: %Self: %I.type = bind_symbolic_name Self, 0 [symbolic] // CHECK:STDOUT: %.1: type = assoc_entity_type %I.type, type [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @I.%T [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @I.%T, element0 [template] // CHECK:STDOUT: %.3: Core.IntLiteral = int_value 32 [template] // CHECK:STDOUT: %Int.type: type = fn_type @Int [template] // CHECK:STDOUT: %Int: %Int.type = struct_value () [template] // CHECK:STDOUT: %i32: type = int_type signed, %.3 [template] // CHECK:STDOUT: %.4: type = assoc_entity_type %I.type, %i32 [template] -// CHECK:STDOUT: %.5: %.4 = assoc_entity element1, @I.%N [template] +// CHECK:STDOUT: %.5: %.4 = assoc_entity @I.%N, element1 [template] // CHECK:STDOUT: } // CHECK:STDOUT: // CHECK:STDOUT: imports { @@ -48,13 +48,13 @@ interface I { // CHECK:STDOUT: interface @I { // CHECK:STDOUT: %Self: %I.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self] // CHECK:STDOUT: %T: type = assoc_const_decl T [template] -// CHECK:STDOUT: %.loc12: %.1 = assoc_entity element0, %T [template = constants.%.2] +// CHECK:STDOUT: %.loc12: %.1 = assoc_entity %T, element0 [template = constants.%.2] // CHECK:STDOUT: %.loc13_11.1: Core.IntLiteral = int_value 32 [template = constants.%.3] // CHECK:STDOUT: %int.make_type_signed: init type = call constants.%Int(%.loc13_11.1) [template = constants.%i32] // CHECK:STDOUT: %.loc13_11.2: type = value_of_initializer %int.make_type_signed [template = constants.%i32] // CHECK:STDOUT: %.loc13_11.3: type = converted %int.make_type_signed, %.loc13_11.2 [template = constants.%i32] // CHECK:STDOUT: %N: %i32 = assoc_const_decl N [template] -// CHECK:STDOUT: %.loc13_14: %.4 = assoc_entity element1, %N [template = constants.%.5] +// CHECK:STDOUT: %.loc13_14: %.4 = assoc_entity %N, element1 [template = constants.%.5] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self diff --git a/toolchain/check/testdata/interface/fail_assoc_const_bad_default.carbon b/toolchain/check/testdata/interface/fail_assoc_const_bad_default.carbon index 1e414705f9fa5..c7ef4e6912518 100644 --- a/toolchain/check/testdata/interface/fail_assoc_const_bad_default.carbon +++ b/toolchain/check/testdata/interface/fail_assoc_const_bad_default.carbon @@ -25,7 +25,7 @@ interface I { // CHECK:STDOUT: %Self.1: %I.type = bind_symbolic_name Self, 0 [symbolic] // CHECK:STDOUT: %.1: Core.IntLiteral = int_value 42 [template] // CHECK:STDOUT: %.25: type = assoc_entity_type %I.type, type [template] -// CHECK:STDOUT: %.26: %.25 = assoc_entity element0, @I.%T [template] +// CHECK:STDOUT: %.26: %.25 = assoc_entity @I.%T, element0 [template] // CHECK:STDOUT: } // CHECK:STDOUT: // CHECK:STDOUT: imports { @@ -50,7 +50,7 @@ interface I { // CHECK:STDOUT: %.loc18_18: Core.IntLiteral = int_value 42 [template = constants.%.1] // CHECK:STDOUT: %.loc18_20.1: type = converted %.loc18_18, [template = ] // CHECK:STDOUT: %T: type = assoc_const_decl T [template] -// CHECK:STDOUT: %.loc18_20.2: %.25 = assoc_entity element0, %T [template = constants.%.26] +// CHECK:STDOUT: %.loc18_20.2: %.25 = assoc_entity %T, element0 [template = constants.%.26] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self diff --git a/toolchain/check/testdata/interface/fail_todo_assoc_const_default.carbon b/toolchain/check/testdata/interface/fail_todo_assoc_const_default.carbon index c6282f5224005..2a841f6adbe7c 100644 --- a/toolchain/check/testdata/interface/fail_todo_assoc_const_default.carbon +++ b/toolchain/check/testdata/interface/fail_todo_assoc_const_default.carbon @@ -32,7 +32,7 @@ interface I { // CHECK:STDOUT: %tuple.type.1: type = tuple_type (type, type) [template] // CHECK:STDOUT: %tuple.type.2: type = tuple_type (%i32, %i32) [template] // CHECK:STDOUT: %.2: type = assoc_entity_type %I.type, type [template] -// CHECK:STDOUT: %.3: %.2 = assoc_entity element0, @I.%T [template] +// CHECK:STDOUT: %.3: %.2 = assoc_entity @I.%T, element0 [template] // CHECK:STDOUT: %.4: Core.IntLiteral = int_value 42 [template] // CHECK:STDOUT: %Convert.type.2: type = fn_type @Convert.1, @ImplicitAs(%i32) [template] // CHECK:STDOUT: %Convert.type.14: type = fn_type @Convert.2, @impl.1(%.1) [template] @@ -42,7 +42,7 @@ interface I { // CHECK:STDOUT: %.30: = specific_function %.29, @Convert.2(%.1) [template] // CHECK:STDOUT: %.31: %i32 = int_value 42 [template] // CHECK:STDOUT: %.32: type = assoc_entity_type %I.type, %i32 [template] -// CHECK:STDOUT: %.33: %.32 = assoc_entity element1, @I.%N [template] +// CHECK:STDOUT: %.33: %.32 = assoc_entity @I.%N, element1 [template] // CHECK:STDOUT: } // CHECK:STDOUT: // CHECK:STDOUT: imports { @@ -76,7 +76,7 @@ interface I { // CHECK:STDOUT: %.loc16_36.4: type = converted %int.make_type_signed.loc16_32, %.loc16_36.3 [template = constants.%i32] // CHECK:STDOUT: %.loc16_36.5: type = converted %.loc16_35, constants.%tuple.type.2 [template = constants.%tuple.type.2] // CHECK:STDOUT: %T: type = assoc_const_decl T [template] -// CHECK:STDOUT: %.loc16_36.6: %.2 = assoc_entity element0, %T [template = constants.%.3] +// CHECK:STDOUT: %.loc16_36.6: %.2 = assoc_entity %T, element0 [template = constants.%.3] // CHECK:STDOUT: %.loc20_19.1: Core.IntLiteral = int_value 32 [template = constants.%.1] // CHECK:STDOUT: %int.make_type_signed.loc20: init type = call constants.%Int(%.loc20_19.1) [template = constants.%i32] // CHECK:STDOUT: %.loc20_19.2: type = value_of_initializer %int.make_type_signed.loc20 [template = constants.%i32] @@ -89,7 +89,7 @@ interface I { // CHECK:STDOUT: %.loc20_27.4: %i32 = value_of_initializer %int.convert_checked [template = constants.%.31] // CHECK:STDOUT: %.loc20_27.5: %i32 = converted %.loc20_25, %.loc20_27.4 [template = constants.%.31] // CHECK:STDOUT: %N: %i32 = assoc_const_decl N [template] -// CHECK:STDOUT: %.loc20_27.6: %.32 = assoc_entity element1, %N [template = constants.%.33] +// CHECK:STDOUT: %.loc20_27.6: %.32 = assoc_entity %N, element1 [template = constants.%.33] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self diff --git a/toolchain/check/testdata/interface/fail_todo_define_default_fn_inline.carbon b/toolchain/check/testdata/interface/fail_todo_define_default_fn_inline.carbon index abeb9af97bd7d..1ce25de332272 100644 --- a/toolchain/check/testdata/interface/fail_todo_define_default_fn_inline.carbon +++ b/toolchain/check/testdata/interface/fail_todo_define_default_fn_inline.carbon @@ -29,7 +29,7 @@ interface Interface { // CHECK:STDOUT: %F.type: type = fn_type @F [template] // CHECK:STDOUT: %F: %F.type = struct_value () [template] // CHECK:STDOUT: %.1: type = assoc_entity_type %Interface.type, %F.type [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @Interface.%F.decl [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @Interface.%F.decl, element0 [template] // CHECK:STDOUT: %.3: Core.IntLiteral = int_value 32 [template] // CHECK:STDOUT: %Int.type: type = fn_type @Int [template] // CHECK:STDOUT: %Int: %Int.type = struct_value () [template] @@ -37,7 +37,7 @@ interface Interface { // CHECK:STDOUT: %G.type: type = fn_type @G [template] // CHECK:STDOUT: %G: %G.type = struct_value () [template] // CHECK:STDOUT: %.4: type = assoc_entity_type %Interface.type, %G.type [template] -// CHECK:STDOUT: %.5: %.4 = assoc_entity element1, @Interface.%G.decl [template] +// CHECK:STDOUT: %.5: %.4 = assoc_entity @Interface.%G.decl, element1 [template] // CHECK:STDOUT: } // CHECK:STDOUT: // CHECK:STDOUT: imports { @@ -60,7 +60,7 @@ interface Interface { // CHECK:STDOUT: interface @Interface { // CHECK:STDOUT: %Self: %Interface.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self] // CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {} {} -// CHECK:STDOUT: %.loc16: %.1 = assoc_entity element0, %F.decl [template = constants.%.2] +// CHECK:STDOUT: %.loc16: %.1 = assoc_entity %F.decl, element0 [template = constants.%.2] // CHECK:STDOUT: %G.decl: %G.type = fn_decl @G [template = constants.%G] { // CHECK:STDOUT: %a.patt: %i32 = binding_pattern a // CHECK:STDOUT: %a.param_patt: %i32 = value_param_pattern %a.patt, runtime_param0 @@ -88,7 +88,7 @@ interface Interface { // CHECK:STDOUT: %return.param: ref %i32 = out_param runtime_param2 // CHECK:STDOUT: %return: ref %i32 = return_slot %return.param // CHECK:STDOUT: } -// CHECK:STDOUT: %.loc21: %.4 = assoc_entity element1, %G.decl [template = constants.%.5] +// CHECK:STDOUT: %.loc21: %.4 = assoc_entity %G.decl, element1 [template = constants.%.5] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self diff --git a/toolchain/check/testdata/interface/fail_todo_define_default_fn_out_of_line.carbon b/toolchain/check/testdata/interface/fail_todo_define_default_fn_out_of_line.carbon index e685eb2c67820..11b33029acbad 100644 --- a/toolchain/check/testdata/interface/fail_todo_define_default_fn_out_of_line.carbon +++ b/toolchain/check/testdata/interface/fail_todo_define_default_fn_out_of_line.carbon @@ -71,7 +71,7 @@ fn Interface.C.F[self: Self](U:! type, u: U) -> U { return u; } // CHECK:STDOUT: %F.type: type = fn_type @F [template] // CHECK:STDOUT: %F: %F.type = struct_value () [template] // CHECK:STDOUT: %.1: type = assoc_entity_type %Interface.type, %F.type [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @Interface.%F.decl [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @Interface.%F.decl, element0 [template] // CHECK:STDOUT: %.3: Core.IntLiteral = int_value 32 [template] // CHECK:STDOUT: %Int.type: type = fn_type @Int [template] // CHECK:STDOUT: %Int: %Int.type = struct_value () [template] @@ -79,7 +79,7 @@ fn Interface.C.F[self: Self](U:! type, u: U) -> U { return u; } // CHECK:STDOUT: %G.type: type = fn_type @G [template] // CHECK:STDOUT: %G: %G.type = struct_value () [template] // CHECK:STDOUT: %.4: type = assoc_entity_type %Interface.type, %G.type [template] -// CHECK:STDOUT: %.5: %.4 = assoc_entity element1, @Interface.%G.decl [template] +// CHECK:STDOUT: %.5: %.4 = assoc_entity @Interface.%G.decl, element1 [template] // CHECK:STDOUT: %.type.1: type = fn_type @.1 [template] // CHECK:STDOUT: %.6: %.type.1 = struct_value () [template] // CHECK:STDOUT: %.type.2: type = fn_type @.2 [template] @@ -134,7 +134,7 @@ fn Interface.C.F[self: Self](U:! type, u: U) -> U { return u; } // CHECK:STDOUT: interface @Interface { // CHECK:STDOUT: %Self: %Interface.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self] // CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {} {} -// CHECK:STDOUT: %.loc7: %.1 = assoc_entity element0, %F.decl [template = constants.%.2] +// CHECK:STDOUT: %.loc7: %.1 = assoc_entity %F.decl, element0 [template = constants.%.2] // CHECK:STDOUT: %G.decl: %G.type = fn_decl @G [template = constants.%G] { // CHECK:STDOUT: %a.patt: %i32 = binding_pattern a // CHECK:STDOUT: %a.param_patt: %i32 = value_param_pattern %a.patt, runtime_param0 @@ -162,7 +162,7 @@ fn Interface.C.F[self: Self](U:! type, u: U) -> U { return u; } // CHECK:STDOUT: %return.param: ref %i32 = out_param runtime_param2 // CHECK:STDOUT: %return: ref %i32 = return_slot %return.param // CHECK:STDOUT: } -// CHECK:STDOUT: %.loc13: %.4 = assoc_entity element1, %G.decl [template = constants.%.5] +// CHECK:STDOUT: %.loc13: %.4 = assoc_entity %G.decl, element1 [template = constants.%.5] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self diff --git a/toolchain/check/testdata/interface/no_prelude/assoc_const_in_generic.carbon b/toolchain/check/testdata/interface/no_prelude/assoc_const_in_generic.carbon index 59cb088e8bc8a..6a2cbb02810dc 100644 --- a/toolchain/check/testdata/interface/no_prelude/assoc_const_in_generic.carbon +++ b/toolchain/check/testdata/interface/no_prelude/assoc_const_in_generic.carbon @@ -38,7 +38,7 @@ fn H() { // CHECK:STDOUT: %F.type.1: type = fn_type @F, @I(%T) [symbolic] // CHECK:STDOUT: %F: %F.type.1 = struct_value () [symbolic] // CHECK:STDOUT: %.1: type = assoc_entity_type %I.type.2, %F.type.1 [symbolic] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @I.%F.decl [symbolic] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @I.%F.decl, element0 [symbolic] // CHECK:STDOUT: %G.type: type = fn_type @G [template] // CHECK:STDOUT: %G: %G.type = struct_value () [template] // CHECK:STDOUT: %H.type: type = fn_type @H [template] @@ -48,7 +48,7 @@ fn H() { // CHECK:STDOUT: %I.type.3: type = facet_type <@I, @I(%.3)> [template] // CHECK:STDOUT: %F.type.2: type = fn_type @F, @I(%.3) [template] // CHECK:STDOUT: %.5: type = assoc_entity_type %I.type.3, %F.type.2 [template] -// CHECK:STDOUT: %.6: %.5 = assoc_entity element0, @I.%F.decl [template] +// CHECK:STDOUT: %.6: %.5 = assoc_entity @I.%F.decl, element0 [template] // CHECK:STDOUT: } // CHECK:STDOUT: // CHECK:STDOUT: file { @@ -84,7 +84,7 @@ fn H() { // CHECK:STDOUT: %F.type: type = fn_type @F, @I(%T.loc11_13.2) [symbolic = %F.type (constants.%F.type.1)] // CHECK:STDOUT: %F: @I.%F.type (%F.type.1) = struct_value () [symbolic = %F (constants.%F)] // CHECK:STDOUT: %.loc12_22.2: type = assoc_entity_type @I.%I.type (%I.type.2), @I.%F.type (%F.type.1) [symbolic = %.loc12_22.2 (constants.%.1)] -// CHECK:STDOUT: %.loc12_22.3: @I.%.loc12_22.2 (%.1) = assoc_entity element0, %F.decl [symbolic = %.loc12_22.3 (constants.%.2)] +// CHECK:STDOUT: %.loc12_22.3: @I.%.loc12_22.2 (%.1) = assoc_entity %F.decl, element0 [symbolic = %.loc12_22.3 (constants.%.2)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: %Self.1: @I.%I.type (%I.type.2) = bind_symbolic_name Self, 1 [symbolic = %Self.2 (constants.%Self)] @@ -100,7 +100,7 @@ fn H() { // CHECK:STDOUT: %return.param: ref @F.%U.loc12_8.1 (%U) = out_param runtime_param0 // CHECK:STDOUT: %return: ref @F.%U.loc12_8.1 (%U) = return_slot %return.param // CHECK:STDOUT: } -// CHECK:STDOUT: %.loc12_22.1: @I.%.loc12_22.2 (%.1) = assoc_entity element0, %F.decl [symbolic = %.loc12_22.3 (constants.%.2)] +// CHECK:STDOUT: %.loc12_22.1: @I.%.loc12_22.2 (%.1) = assoc_entity %F.decl, element0 [symbolic = %.loc12_22.3 (constants.%.2)] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self.1 @@ -124,7 +124,7 @@ fn H() { // CHECK:STDOUT: %I.type.loc19_4.2: type = facet_type <@I, @I(%T.loc15_6.2)> [symbolic = %I.type.loc19_4.2 (constants.%I.type.2)] // CHECK:STDOUT: %F.type: type = fn_type @F, @I(%T.loc15_6.2) [symbolic = %F.type (constants.%F.type.1)] // CHECK:STDOUT: %.loc19_7.2: type = assoc_entity_type @G.%I.type.loc19_4.2 (%I.type.2), @G.%F.type (%F.type.1) [symbolic = %.loc19_7.2 (constants.%.1)] -// CHECK:STDOUT: %.loc19_7.3: @G.%.loc19_7.2 (%.1) = assoc_entity element0, @I.%F.decl [symbolic = %.loc19_7.3 (constants.%.2)] +// CHECK:STDOUT: %.loc19_7.3: @G.%.loc19_7.2 (%.1) = assoc_entity @I.%F.decl, element0 [symbolic = %.loc19_7.3 (constants.%.2)] // CHECK:STDOUT: // CHECK:STDOUT: fn(%T.param_patt: type) { // CHECK:STDOUT: !entry: diff --git a/toolchain/check/testdata/interface/no_prelude/basic.carbon b/toolchain/check/testdata/interface/no_prelude/basic.carbon index 912b85e4488e7..bb31cfaf25215 100644 --- a/toolchain/check/testdata/interface/no_prelude/basic.carbon +++ b/toolchain/check/testdata/interface/no_prelude/basic.carbon @@ -27,7 +27,7 @@ interface ForwardDeclared { // CHECK:STDOUT: %F.type: type = fn_type @F [template] // CHECK:STDOUT: %F: %F.type = struct_value () [template] // CHECK:STDOUT: %.1: type = assoc_entity_type %ForwardDeclared.type, %F.type [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @ForwardDeclared.%F.decl [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @ForwardDeclared.%F.decl, element0 [template] // CHECK:STDOUT: } // CHECK:STDOUT: // CHECK:STDOUT: file { @@ -51,7 +51,7 @@ interface ForwardDeclared { // CHECK:STDOUT: interface @ForwardDeclared { // CHECK:STDOUT: %Self: %ForwardDeclared.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self.2] // CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {} {} -// CHECK:STDOUT: %.loc17: %.1 = assoc_entity element0, %F.decl [template = constants.%.2] +// CHECK:STDOUT: %.loc17: %.1 = assoc_entity %F.decl, element0 [template = constants.%.2] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self diff --git a/toolchain/check/testdata/interface/no_prelude/default_fn.carbon b/toolchain/check/testdata/interface/no_prelude/default_fn.carbon index ef846ade5b0bd..cfe504a8658b1 100644 --- a/toolchain/check/testdata/interface/no_prelude/default_fn.carbon +++ b/toolchain/check/testdata/interface/no_prelude/default_fn.carbon @@ -33,7 +33,7 @@ class C { // CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [template] // CHECK:STDOUT: %F.1: %F.type.1 = struct_value () [template] // CHECK:STDOUT: %.1: type = assoc_entity_type %I.type, %F.type.1 [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @I.%F.decl [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @I.%F.decl, element0 [template] // CHECK:STDOUT: %F.type.2: type = fn_type @F.2 [template] // CHECK:STDOUT: %F.2: %F.type.2 = struct_value () [template] // CHECK:STDOUT: %.3: %I.type = facet_value %C, %C [template] @@ -53,7 +53,7 @@ class C { // CHECK:STDOUT: interface @I { // CHECK:STDOUT: %Self: %I.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self] // CHECK:STDOUT: %F.decl: %F.type.1 = fn_decl @F.1 [template = constants.%F.1] {} {} -// CHECK:STDOUT: %.loc14: %.1 = assoc_entity element0, %F.decl [template = constants.%.2] +// CHECK:STDOUT: %.loc14: %.1 = assoc_entity %F.decl, element0 [template = constants.%.2] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self diff --git a/toolchain/check/testdata/interface/no_prelude/fail_duplicate.carbon b/toolchain/check/testdata/interface/no_prelude/fail_duplicate.carbon index 683fdaf39be3a..5e0d03d42dc82 100644 --- a/toolchain/check/testdata/interface/no_prelude/fail_duplicate.carbon +++ b/toolchain/check/testdata/interface/no_prelude/fail_duplicate.carbon @@ -79,7 +79,7 @@ interface Class { } // CHECK:STDOUT: %F.type: type = fn_type @F [template] // CHECK:STDOUT: %F: %F.type = struct_value () [template] // CHECK:STDOUT: %.1: type = assoc_entity_type %.type, %F.type [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @.1.%F.decl [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @.1.%F.decl, element0 [template] // CHECK:STDOUT: } // CHECK:STDOUT: // CHECK:STDOUT: file { @@ -101,7 +101,7 @@ interface Class { } // CHECK:STDOUT: interface @.1 { // CHECK:STDOUT: %Self: %.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self.2] // CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {} {} -// CHECK:STDOUT: %.loc14: %.1 = assoc_entity element0, %F.decl [template = constants.%.2] +// CHECK:STDOUT: %.loc14: %.1 = assoc_entity %F.decl, element0 [template = constants.%.2] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self @@ -127,7 +127,7 @@ interface Class { } // CHECK:STDOUT: %F.type: type = fn_type @F [template] // CHECK:STDOUT: %F: %F.type = struct_value () [template] // CHECK:STDOUT: %.2: type = assoc_entity_type %.type, %F.type [template] -// CHECK:STDOUT: %.3: %.2 = assoc_entity element0, @.1.%F.decl [template] +// CHECK:STDOUT: %.3: %.2 = assoc_entity @.1.%F.decl, element0 [template] // CHECK:STDOUT: } // CHECK:STDOUT: // CHECK:STDOUT: file { @@ -158,7 +158,7 @@ interface Class { } // CHECK:STDOUT: %self.param: @F.%.loc14_14.1 (%.1) = value_param runtime_param0 // CHECK:STDOUT: %self: @F.%.loc14_14.1 (%.1) = bind_name self, %self.param // CHECK:STDOUT: } -// CHECK:STDOUT: %.loc14: %.2 = assoc_entity element0, %F.decl [template = constants.%.3] +// CHECK:STDOUT: %.loc14: %.2 = assoc_entity %F.decl, element0 [template = constants.%.3] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self diff --git a/toolchain/check/testdata/interface/no_prelude/fail_lookup_undefined.carbon b/toolchain/check/testdata/interface/no_prelude/fail_lookup_undefined.carbon index 2ed39d25b88d3..447a62d3d89da 100644 --- a/toolchain/check/testdata/interface/no_prelude/fail_lookup_undefined.carbon +++ b/toolchain/check/testdata/interface/no_prelude/fail_lookup_undefined.carbon @@ -62,7 +62,7 @@ interface BeingDefined { // CHECK:STDOUT: %H.type: type = fn_type @H [template] // CHECK:STDOUT: %H: %H.type = struct_value () [template] // CHECK:STDOUT: %.2: type = assoc_entity_type %BeingDefined.type, %H.type [template] -// CHECK:STDOUT: %.3: %.2 = assoc_entity element0, @BeingDefined.%H.decl [template] +// CHECK:STDOUT: %.3: %.2 = assoc_entity @BeingDefined.%H.decl, element0 [template] // CHECK:STDOUT: %.type.2: type = fn_type @.2 [template] // CHECK:STDOUT: %.4: %.type.2 = struct_value () [template] // CHECK:STDOUT: } @@ -92,7 +92,7 @@ interface BeingDefined { // CHECK:STDOUT: %return.param: ref = out_param runtime_param0 // CHECK:STDOUT: %return: ref = return_slot %return.param // CHECK:STDOUT: } -// CHECK:STDOUT: %.loc45: %.2 = assoc_entity element0, %H.decl [template = constants.%.3] +// CHECK:STDOUT: %.loc45: %.2 = assoc_entity %H.decl, element0 [template = constants.%.3] // CHECK:STDOUT: %.decl: %.type.2 = fn_decl @.2 [template = constants.%.4] {} {} // CHECK:STDOUT: // CHECK:STDOUT: !members: diff --git a/toolchain/check/testdata/interface/no_prelude/fail_member_lookup.carbon b/toolchain/check/testdata/interface/no_prelude/fail_member_lookup.carbon index c63f847d0ea9b..7ca7dcef9779b 100644 --- a/toolchain/check/testdata/interface/no_prelude/fail_member_lookup.carbon +++ b/toolchain/check/testdata/interface/no_prelude/fail_member_lookup.carbon @@ -43,9 +43,9 @@ fn G(U:! Different) -> U.(Interface.T); // CHECK:STDOUT: %F.type.1: type = fn_type @F.1 [template] // CHECK:STDOUT: %F.1: %F.type.1 = struct_value () [template] // CHECK:STDOUT: %.1: type = assoc_entity_type %Interface.type, %F.type.1 [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @Interface.%F.decl [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @Interface.%F.decl, element0 [template] // CHECK:STDOUT: %.3: type = assoc_entity_type %Interface.type, type [template] -// CHECK:STDOUT: %.4: %.3 = assoc_entity element1, @Interface.%T [template] +// CHECK:STDOUT: %.4: %.3 = assoc_entity @Interface.%T, element1 [template] // CHECK:STDOUT: %F.type.2: type = fn_type @F.2 [template] // CHECK:STDOUT: %F.2: %F.type.2 = struct_value () [template] // CHECK:STDOUT: %Different.type: type = facet_type <@Different> [template] @@ -86,9 +86,9 @@ fn G(U:! Different) -> U.(Interface.T); // CHECK:STDOUT: interface @Interface { // CHECK:STDOUT: %Self: %Interface.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self.1] // CHECK:STDOUT: %F.decl: %F.type.1 = fn_decl @F.1 [template = constants.%F.1] {} {} -// CHECK:STDOUT: %.loc12: %.1 = assoc_entity element0, %F.decl [template = constants.%.2] +// CHECK:STDOUT: %.loc12: %.1 = assoc_entity %F.decl, element0 [template = constants.%.2] // CHECK:STDOUT: %T: type = assoc_const_decl T [template] -// CHECK:STDOUT: %.loc14: %.3 = assoc_entity element1, %T [template = constants.%.4] +// CHECK:STDOUT: %.loc14: %.3 = assoc_entity %T, element1 [template = constants.%.4] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self diff --git a/toolchain/check/testdata/interface/no_prelude/fail_modifiers.carbon b/toolchain/check/testdata/interface/no_prelude/fail_modifiers.carbon index e2ab1adc7dad7..03e6b59dd7fbe 100644 --- a/toolchain/check/testdata/interface/no_prelude/fail_modifiers.carbon +++ b/toolchain/check/testdata/interface/no_prelude/fail_modifiers.carbon @@ -156,7 +156,7 @@ interface I { // CHECK:STDOUT: %F.type: type = fn_type @F [template] // CHECK:STDOUT: %F: %F.type = struct_value () [template] // CHECK:STDOUT: %.2: type = assoc_entity_type %I.type, %F.type [template] -// CHECK:STDOUT: %.3: %.2 = assoc_entity element0, @I.%F.decl [template] +// CHECK:STDOUT: %.3: %.2 = assoc_entity @I.%F.decl, element0 [template] // CHECK:STDOUT: } // CHECK:STDOUT: // CHECK:STDOUT: file { @@ -178,7 +178,7 @@ interface I { // CHECK:STDOUT: %self.param: @F.%.loc9_22.1 (%.1) = value_param runtime_param0 // CHECK:STDOUT: %self: @F.%.loc9_22.1 (%.1) = bind_name self, %self.param // CHECK:STDOUT: } -// CHECK:STDOUT: %.loc9: %.2 = assoc_entity element0, %F.decl [template = constants.%.3] +// CHECK:STDOUT: %.loc9: %.2 = assoc_entity %F.decl, element0 [template = constants.%.3] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self @@ -207,7 +207,7 @@ interface I { // CHECK:STDOUT: %F.type: type = fn_type @F [template] // CHECK:STDOUT: %F: %F.type = struct_value () [template] // CHECK:STDOUT: %.2: type = assoc_entity_type %I.type, %F.type [template] -// CHECK:STDOUT: %.3: %.2 = assoc_entity element0, @I.%F.decl [template] +// CHECK:STDOUT: %.3: %.2 = assoc_entity @I.%F.decl, element0 [template] // CHECK:STDOUT: } // CHECK:STDOUT: // CHECK:STDOUT: file { @@ -229,7 +229,7 @@ interface I { // CHECK:STDOUT: %self.param: @F.%.loc8_24.1 (%.1) = value_param runtime_param0 // CHECK:STDOUT: %self: @F.%.loc8_24.1 (%.1) = bind_name self, %self.param // CHECK:STDOUT: } -// CHECK:STDOUT: %.loc8: %.2 = assoc_entity element0, %F.decl [template = constants.%.3] +// CHECK:STDOUT: %.loc8: %.2 = assoc_entity %F.decl, element0 [template = constants.%.3] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self diff --git a/toolchain/check/testdata/interface/no_prelude/fail_redeclare_member.carbon b/toolchain/check/testdata/interface/no_prelude/fail_redeclare_member.carbon index 7bf7a8d80f60c..bed218380b91b 100644 --- a/toolchain/check/testdata/interface/no_prelude/fail_redeclare_member.carbon +++ b/toolchain/check/testdata/interface/no_prelude/fail_redeclare_member.carbon @@ -27,7 +27,7 @@ interface Interface { // CHECK:STDOUT: %F.type: type = fn_type @F [template] // CHECK:STDOUT: %F: %F.type = struct_value () [template] // CHECK:STDOUT: %.1: type = assoc_entity_type %Interface.type, %F.type [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @Interface.%F.decl [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @Interface.%F.decl, element0 [template] // CHECK:STDOUT: %.type: type = fn_type @.1 [template] // CHECK:STDOUT: %.3: %.type = struct_value () [template] // CHECK:STDOUT: } @@ -42,7 +42,7 @@ interface Interface { // CHECK:STDOUT: interface @Interface { // CHECK:STDOUT: %Self: %Interface.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self] // CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {} {} -// CHECK:STDOUT: %.loc12: %.1 = assoc_entity element0, %F.decl [template = constants.%.2] +// CHECK:STDOUT: %.loc12: %.1 = assoc_entity %F.decl, element0 [template = constants.%.2] // CHECK:STDOUT: %.decl: %.type = fn_decl @.1 [template = constants.%.3] {} {} // CHECK:STDOUT: // CHECK:STDOUT: !members: diff --git a/toolchain/check/testdata/interface/no_prelude/fail_todo_facet_lookup.carbon b/toolchain/check/testdata/interface/no_prelude/fail_todo_facet_lookup.carbon index b65c8745e96b6..683993a9a3581 100644 --- a/toolchain/check/testdata/interface/no_prelude/fail_todo_facet_lookup.carbon +++ b/toolchain/check/testdata/interface/no_prelude/fail_todo_facet_lookup.carbon @@ -33,7 +33,7 @@ fn CallFacet(T:! Interface, x: T) { // CHECK:STDOUT: %F.type: type = fn_type @F [template] // CHECK:STDOUT: %F: %F.type = struct_value () [template] // CHECK:STDOUT: %.1: type = assoc_entity_type %Interface.type, %F.type [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @Interface.%F.decl [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @Interface.%F.decl, element0 [template] // CHECK:STDOUT: %T: %Interface.type = bind_symbolic_name T, 0 [symbolic] // CHECK:STDOUT: %T.patt: %Interface.type = symbolic_binding_pattern T, 0 [symbolic] // CHECK:STDOUT: %CallStatic.type: type = fn_type @CallStatic [template] @@ -80,7 +80,7 @@ fn CallFacet(T:! Interface, x: T) { // CHECK:STDOUT: interface @Interface { // CHECK:STDOUT: %Self: %Interface.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self] // CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {} {} -// CHECK:STDOUT: %.loc11: %.1 = assoc_entity element0, %F.decl [template = constants.%.2] +// CHECK:STDOUT: %.loc11: %.1 = assoc_entity %F.decl, element0 [template = constants.%.2] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self diff --git a/toolchain/check/testdata/interface/no_prelude/fail_todo_generic_default_fn.carbon b/toolchain/check/testdata/interface/no_prelude/fail_todo_generic_default_fn.carbon index 18165de0f4db3..68a7ee85cd6db 100644 --- a/toolchain/check/testdata/interface/no_prelude/fail_todo_generic_default_fn.carbon +++ b/toolchain/check/testdata/interface/no_prelude/fail_todo_generic_default_fn.carbon @@ -34,7 +34,7 @@ fn I(T:! type).F[self: Self]() -> Self { return self; } // CHECK:STDOUT: %F.type: type = fn_type @F, @I(%T) [symbolic] // CHECK:STDOUT: %F: %F.type = struct_value () [symbolic] // CHECK:STDOUT: %.2: type = assoc_entity_type %I.type.2, %F.type [symbolic] -// CHECK:STDOUT: %.3: %.2 = assoc_entity element0, @I.%F.decl [symbolic] +// CHECK:STDOUT: %.3: %.2 = assoc_entity @I.%F.decl, element0 [symbolic] // CHECK:STDOUT: %.type: type = fn_type @.1, @I(%T) [symbolic] // CHECK:STDOUT: %.4: %.type = struct_value () [symbolic] // CHECK:STDOUT: } @@ -83,7 +83,7 @@ fn I(T:! type).F[self: Self]() -> Self { return self; } // CHECK:STDOUT: %F.type: type = fn_type @F, @I(%T.loc11_13.2) [symbolic = %F.type (constants.%F.type)] // CHECK:STDOUT: %F: @I.%F.type (%F.type) = struct_value () [symbolic = %F (constants.%F)] // CHECK:STDOUT: %.loc13_29.2: type = assoc_entity_type @I.%I.type (%I.type.2), @I.%F.type (%F.type) [symbolic = %.loc13_29.2 (constants.%.2)] -// CHECK:STDOUT: %.loc13_29.3: @I.%.loc13_29.2 (%.2) = assoc_entity element0, %F.decl [symbolic = %.loc13_29.3 (constants.%.3)] +// CHECK:STDOUT: %.loc13_29.3: @I.%.loc13_29.2 (%.2) = assoc_entity %F.decl, element0 [symbolic = %.loc13_29.3 (constants.%.3)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: %Self.1: @I.%I.type (%I.type.2) = bind_symbolic_name Self, 1 [symbolic = %Self.2 (constants.%Self)] @@ -106,7 +106,7 @@ fn I(T:! type).F[self: Self]() -> Self { return self; } // CHECK:STDOUT: %return.param: ref @F.%.loc13_14.1 (%.1) = out_param runtime_param1 // CHECK:STDOUT: %return: ref @F.%.loc13_14.1 (%.1) = return_slot %return.param // CHECK:STDOUT: } -// CHECK:STDOUT: %.loc13_29.1: @I.%.loc13_29.2 (%.2) = assoc_entity element0, %F.decl [symbolic = %.loc13_29.3 (constants.%.3)] +// CHECK:STDOUT: %.loc13_29.1: @I.%.loc13_29.2 (%.2) = assoc_entity %F.decl, element0 [symbolic = %.loc13_29.3 (constants.%.3)] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self.1 diff --git a/toolchain/check/testdata/interface/no_prelude/fail_todo_modifiers.carbon b/toolchain/check/testdata/interface/no_prelude/fail_todo_modifiers.carbon index 332ad577d7cf6..a4bf80480bd40 100644 --- a/toolchain/check/testdata/interface/no_prelude/fail_todo_modifiers.carbon +++ b/toolchain/check/testdata/interface/no_prelude/fail_todo_modifiers.carbon @@ -28,11 +28,11 @@ interface Modifiers { // CHECK:STDOUT: %Final.type: type = fn_type @Final [template] // CHECK:STDOUT: %Final: %Final.type = struct_value () [template] // CHECK:STDOUT: %.1: type = assoc_entity_type %Modifiers.type, %Final.type [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @Modifiers.%Final.decl [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @Modifiers.%Final.decl, element0 [template] // CHECK:STDOUT: %Default.type: type = fn_type @Default [template] // CHECK:STDOUT: %Default: %Default.type = struct_value () [template] // CHECK:STDOUT: %.3: type = assoc_entity_type %Modifiers.type, %Default.type [template] -// CHECK:STDOUT: %.4: %.3 = assoc_entity element1, @Modifiers.%Default.decl [template] +// CHECK:STDOUT: %.4: %.3 = assoc_entity @Modifiers.%Default.decl, element1 [template] // CHECK:STDOUT: } // CHECK:STDOUT: // CHECK:STDOUT: file { @@ -45,9 +45,9 @@ interface Modifiers { // CHECK:STDOUT: interface @Modifiers { // CHECK:STDOUT: %Self: %Modifiers.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self] // CHECK:STDOUT: %Final.decl: %Final.type = fn_decl @Final [template = constants.%Final] {} {} -// CHECK:STDOUT: %.loc16: %.1 = assoc_entity element0, %Final.decl [template = constants.%.2] +// CHECK:STDOUT: %.loc16: %.1 = assoc_entity %Final.decl, element0 [template = constants.%.2] // CHECK:STDOUT: %Default.decl: %Default.type = fn_decl @Default [template = constants.%Default] {} {} -// CHECK:STDOUT: %.loc20: %.3 = assoc_entity element1, %Default.decl [template = constants.%.4] +// CHECK:STDOUT: %.loc20: %.3 = assoc_entity %Default.decl, element1 [template = constants.%.4] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self diff --git a/toolchain/check/testdata/interface/no_prelude/generic.carbon b/toolchain/check/testdata/interface/no_prelude/generic.carbon index ba39bae97e6d1..2222e433fce86 100644 --- a/toolchain/check/testdata/interface/no_prelude/generic.carbon +++ b/toolchain/check/testdata/interface/no_prelude/generic.carbon @@ -78,7 +78,7 @@ fn G(T:! Generic(B)) { // CHECK:STDOUT: %F.type.1: type = fn_type @F.1, @WithAssocFn(%T.1) [symbolic] // CHECK:STDOUT: %F.1: %F.type.1 = struct_value () [symbolic] // CHECK:STDOUT: %.3: type = assoc_entity_type %WithAssocFn.type.2, %F.type.1 [symbolic] -// CHECK:STDOUT: %.4: %.3 = assoc_entity element0, @WithAssocFn.%F.decl [symbolic] +// CHECK:STDOUT: %.4: %.3 = assoc_entity @WithAssocFn.%F.decl, element0 [symbolic] // CHECK:STDOUT: %C: type = class_type @C [template] // CHECK:STDOUT: %Simple.type.3: type = facet_type <@Simple, @Simple(%C)> [template] // CHECK:STDOUT: %.5: = interface_witness () [template] @@ -88,7 +88,7 @@ fn G(T:! Generic(B)) { // CHECK:STDOUT: %F.type.3: type = fn_type @F.1, @WithAssocFn(%C) [template] // CHECK:STDOUT: %F.3: %F.type.3 = struct_value () [template] // CHECK:STDOUT: %.6: type = assoc_entity_type %WithAssocFn.type.3, %F.type.3 [template] -// CHECK:STDOUT: %.7: %.6 = assoc_entity element0, @WithAssocFn.%F.decl [template] +// CHECK:STDOUT: %.7: %.6 = assoc_entity @WithAssocFn.%F.decl, element0 [template] // CHECK:STDOUT: %.8: %WithAssocFn.type.2 = facet_value %C, %C [symbolic] // CHECK:STDOUT: %.9: = interface_witness (%F.2) [template] // CHECK:STDOUT: %struct: %X = struct_value () [template] @@ -192,7 +192,7 @@ fn G(T:! Generic(B)) { // CHECK:STDOUT: %F.type: type = fn_type @F.1, @WithAssocFn(%T.loc8_23.2) [symbolic = %F.type (constants.%F.type.1)] // CHECK:STDOUT: %F: @WithAssocFn.%F.type (%F.type.1) = struct_value () [symbolic = %F (constants.%F.1)] // CHECK:STDOUT: %.loc10_14.2: type = assoc_entity_type @WithAssocFn.%WithAssocFn.type (%WithAssocFn.type.2), @WithAssocFn.%F.type (%F.type.1) [symbolic = %.loc10_14.2 (constants.%.3)] -// CHECK:STDOUT: %.loc10_14.3: @WithAssocFn.%.loc10_14.2 (%.3) = assoc_entity element0, %F.decl [symbolic = %.loc10_14.3 (constants.%.4)] +// CHECK:STDOUT: %.loc10_14.3: @WithAssocFn.%.loc10_14.2 (%.3) = assoc_entity %F.decl, element0 [symbolic = %.loc10_14.3 (constants.%.4)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: %Self.1: @WithAssocFn.%WithAssocFn.type (%WithAssocFn.type.2) = bind_symbolic_name Self, 1 [symbolic = %Self.2 (constants.%Self.2)] @@ -204,7 +204,7 @@ fn G(T:! Generic(B)) { // CHECK:STDOUT: %return.param: ref %X = out_param runtime_param0 // CHECK:STDOUT: %return: ref %X = return_slot %return.param // CHECK:STDOUT: } -// CHECK:STDOUT: %.loc10_14.1: @WithAssocFn.%.loc10_14.2 (%.3) = assoc_entity element0, %F.decl [symbolic = %.loc10_14.3 (constants.%.4)] +// CHECK:STDOUT: %.loc10_14.1: @WithAssocFn.%.loc10_14.2 (%.3) = assoc_entity %F.decl, element0 [symbolic = %.loc10_14.3 (constants.%.4)] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self.1 diff --git a/toolchain/check/testdata/interface/no_prelude/generic_binding_after_assoc_const.carbon b/toolchain/check/testdata/interface/no_prelude/generic_binding_after_assoc_const.carbon index 787a606ba78fb..6b224ca5fd0d0 100644 --- a/toolchain/check/testdata/interface/no_prelude/generic_binding_after_assoc_const.carbon +++ b/toolchain/check/testdata/interface/no_prelude/generic_binding_after_assoc_const.carbon @@ -26,13 +26,13 @@ interface I { // CHECK:STDOUT: %F.type: type = fn_type @F [template] // CHECK:STDOUT: %F: %F.type = struct_value () [template] // CHECK:STDOUT: %.1: type = assoc_entity_type %I.type, %F.type [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @I.%F.decl [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @I.%F.decl, element0 [template] // CHECK:STDOUT: %.3: type = assoc_entity_type %I.type, type [template] -// CHECK:STDOUT: %.4: %.3 = assoc_entity element1, @I.%U [template] +// CHECK:STDOUT: %.4: %.3 = assoc_entity @I.%U, element1 [template] // CHECK:STDOUT: %G.type: type = fn_type @G [template] // CHECK:STDOUT: %G: %G.type = struct_value () [template] // CHECK:STDOUT: %.5: type = assoc_entity_type %I.type, %G.type [template] -// CHECK:STDOUT: %.6: %.5 = assoc_entity element2, @I.%G.decl [template] +// CHECK:STDOUT: %.6: %.5 = assoc_entity @I.%G.decl, element2 [template] // CHECK:STDOUT: } // CHECK:STDOUT: // CHECK:STDOUT: file { @@ -51,9 +51,9 @@ interface I { // CHECK:STDOUT: %T.param: type = value_param runtime_param // CHECK:STDOUT: %T.loc12_8.2: type = bind_symbolic_name T, 1, %T.param [symbolic = %T.loc12_8.1 (constants.%T)] // CHECK:STDOUT: } -// CHECK:STDOUT: %.loc12: %.1 = assoc_entity element0, %F.decl [template = constants.%.2] +// CHECK:STDOUT: %.loc12: %.1 = assoc_entity %F.decl, element0 [template = constants.%.2] // CHECK:STDOUT: %U: type = assoc_const_decl U [template] -// CHECK:STDOUT: %.loc13: %.3 = assoc_entity element1, %U [template = constants.%.4] +// CHECK:STDOUT: %.loc13: %.3 = assoc_entity %U, element1 [template = constants.%.4] // CHECK:STDOUT: %G.decl: %G.type = fn_decl @G [template = constants.%G] { // CHECK:STDOUT: %T.patt.loc16_8.2: type = symbolic_binding_pattern T, 1 [symbolic = %T.patt.loc16_8.1 (constants.%T.patt)] // CHECK:STDOUT: %T.param_patt: type = value_param_pattern %T.patt.loc16_8.2, runtime_param [symbolic = %T.patt.loc16_8.1 (constants.%T.patt)] @@ -61,7 +61,7 @@ interface I { // CHECK:STDOUT: %T.param: type = value_param runtime_param // CHECK:STDOUT: %T.loc16_8.2: type = bind_symbolic_name T, 1, %T.param [symbolic = %T.loc16_8.1 (constants.%T)] // CHECK:STDOUT: } -// CHECK:STDOUT: %.loc16: %.5 = assoc_entity element2, %G.decl [template = constants.%.6] +// CHECK:STDOUT: %.loc16: %.5 = assoc_entity %G.decl, element2 [template = constants.%.6] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self diff --git a/toolchain/check/testdata/interface/no_prelude/generic_import.carbon b/toolchain/check/testdata/interface/no_prelude/generic_import.carbon index fc8aad9cdb985..ce85a90b0d9ef 100644 --- a/toolchain/check/testdata/interface/no_prelude/generic_import.carbon +++ b/toolchain/check/testdata/interface/no_prelude/generic_import.carbon @@ -39,7 +39,7 @@ impl C as AddWith(C) { // CHECK:STDOUT: %F.type: type = fn_type @F, @AddWith(%T) [symbolic] // CHECK:STDOUT: %F: %F.type = struct_value () [symbolic] // CHECK:STDOUT: %.1: type = assoc_entity_type %AddWith.type.2, %F.type [symbolic] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @AddWith.%F.decl [symbolic] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @AddWith.%F.decl, element0 [symbolic] // CHECK:STDOUT: } // CHECK:STDOUT: // CHECK:STDOUT: file { @@ -65,12 +65,12 @@ impl C as AddWith(C) { // CHECK:STDOUT: %F.type: type = fn_type @F, @AddWith(%T.loc4_19.2) [symbolic = %F.type (constants.%F.type)] // CHECK:STDOUT: %F: @AddWith.%F.type (%F.type) = struct_value () [symbolic = %F (constants.%F)] // CHECK:STDOUT: %.loc5_9.2: type = assoc_entity_type @AddWith.%AddWith.type (%AddWith.type.2), @AddWith.%F.type (%F.type) [symbolic = %.loc5_9.2 (constants.%.1)] -// CHECK:STDOUT: %.loc5_9.3: @AddWith.%.loc5_9.2 (%.1) = assoc_entity element0, %F.decl [symbolic = %.loc5_9.3 (constants.%.2)] +// CHECK:STDOUT: %.loc5_9.3: @AddWith.%.loc5_9.2 (%.1) = assoc_entity %F.decl, element0 [symbolic = %.loc5_9.3 (constants.%.2)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: %Self.1: @AddWith.%AddWith.type (%AddWith.type.2) = bind_symbolic_name Self, 1 [symbolic = %Self.2 (constants.%Self)] // CHECK:STDOUT: %F.decl: @AddWith.%F.type (%F.type) = fn_decl @F [symbolic = @AddWith.%F (constants.%F)] {} {} -// CHECK:STDOUT: %.loc5_9.1: @AddWith.%.loc5_9.2 (%.1) = assoc_entity element0, %F.decl [symbolic = %.loc5_9.3 (constants.%.2)] +// CHECK:STDOUT: %.loc5_9.1: @AddWith.%.loc5_9.2 (%.1) = assoc_entity %F.decl, element0 [symbolic = %.loc5_9.3 (constants.%.2)] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self.1 @@ -112,14 +112,14 @@ impl C as AddWith(C) { // CHECK:STDOUT: %F.type.1: type = fn_type @F.1, @AddWith(%T) [symbolic] // CHECK:STDOUT: %F.1: %F.type.1 = struct_value () [symbolic] // CHECK:STDOUT: %.3: type = assoc_entity_type %AddWith.type.2, %F.type.1 [symbolic] -// CHECK:STDOUT: %.4: %.3 = assoc_entity element0, imports.%import_ref.5 [symbolic] +// CHECK:STDOUT: %.4: %.3 = assoc_entity imports.%import_ref.5, element0 [symbolic] // CHECK:STDOUT: %AddWith.type.3: type = facet_type <@AddWith, @AddWith(%C)> [template] // CHECK:STDOUT: %F.type.2: type = fn_type @F.2 [template] // CHECK:STDOUT: %F.2: %F.type.2 = struct_value () [template] // CHECK:STDOUT: %F.type.3: type = fn_type @F.1, @AddWith(%C) [template] // CHECK:STDOUT: %F.3: %F.type.3 = struct_value () [template] // CHECK:STDOUT: %.5: type = assoc_entity_type %AddWith.type.3, %F.type.3 [template] -// CHECK:STDOUT: %.6: %.5 = assoc_entity element0, imports.%import_ref.5 [template] +// CHECK:STDOUT: %.6: %.5 = assoc_entity imports.%import_ref.5, element0 [template] // CHECK:STDOUT: %.7: %AddWith.type.2 = facet_value %C, %C [symbolic] // CHECK:STDOUT: %.8: = interface_witness (%F.2) [template] // CHECK:STDOUT: } @@ -157,7 +157,7 @@ impl C as AddWith(C) { // CHECK:STDOUT: %F.type: type = fn_type @F.1, @AddWith(%T) [symbolic = %F.type (constants.%F.type.1)] // CHECK:STDOUT: %F: @AddWith.%F.type (%F.type.1) = struct_value () [symbolic = %F (constants.%F.1)] // CHECK:STDOUT: %.1: type = assoc_entity_type @AddWith.%AddWith.type (%AddWith.type.2), @AddWith.%F.type (%F.type.1) [symbolic = %.1 (constants.%.3)] -// CHECK:STDOUT: %.2: @AddWith.%.1 (%.3) = assoc_entity element0, imports.%import_ref.5 [symbolic = %.2 (constants.%.4)] +// CHECK:STDOUT: %.2: @AddWith.%.1 (%.3) = assoc_entity imports.%import_ref.5, element0 [symbolic = %.2 (constants.%.4)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: !members: diff --git a/toolchain/check/testdata/interface/no_prelude/import.carbon b/toolchain/check/testdata/interface/no_prelude/import.carbon index 85e780721c9b5..e6130048f45fd 100644 --- a/toolchain/check/testdata/interface/no_prelude/import.carbon +++ b/toolchain/check/testdata/interface/no_prelude/import.carbon @@ -56,19 +56,19 @@ var f: ForwardDeclared* = &f_ref.f; // CHECK:STDOUT: %Basic.type: type = facet_type <@Basic> [template] // CHECK:STDOUT: %Self.2: %Basic.type = bind_symbolic_name Self, 0 [symbolic] // CHECK:STDOUT: %.1: type = assoc_entity_type %Basic.type, type [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @Basic.%T [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @Basic.%T, element0 [template] // CHECK:STDOUT: %F.type.1: type = fn_type @F.1 [template] // CHECK:STDOUT: %F.1: %F.type.1 = struct_value () [template] // CHECK:STDOUT: %.3: type = assoc_entity_type %Basic.type, %F.type.1 [template] -// CHECK:STDOUT: %.4: %.3 = assoc_entity element1, @Basic.%F.decl [template] +// CHECK:STDOUT: %.4: %.3 = assoc_entity @Basic.%F.decl, element1 [template] // CHECK:STDOUT: %ForwardDeclared.type: type = facet_type <@ForwardDeclared> [template] // CHECK:STDOUT: %Self.3: %ForwardDeclared.type = bind_symbolic_name Self, 0 [symbolic] // CHECK:STDOUT: %.5: type = assoc_entity_type %ForwardDeclared.type, type [template] -// CHECK:STDOUT: %.6: %.5 = assoc_entity element0, @ForwardDeclared.%T [template] +// CHECK:STDOUT: %.6: %.5 = assoc_entity @ForwardDeclared.%T, element0 [template] // CHECK:STDOUT: %F.type.2: type = fn_type @F.2 [template] // CHECK:STDOUT: %F.2: %F.type.2 = struct_value () [template] // CHECK:STDOUT: %.7: type = assoc_entity_type %ForwardDeclared.type, %F.type.2 [template] -// CHECK:STDOUT: %.8: %.7 = assoc_entity element1, @ForwardDeclared.%F.decl [template] +// CHECK:STDOUT: %.8: %.7 = assoc_entity @ForwardDeclared.%F.decl, element1 [template] // CHECK:STDOUT: %.9: type = struct_type {.f: %ForwardDeclared.type} [template] // CHECK:STDOUT: } // CHECK:STDOUT: @@ -99,9 +99,9 @@ var f: ForwardDeclared* = &f_ref.f; // CHECK:STDOUT: interface @Basic { // CHECK:STDOUT: %Self: %Basic.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self.2] // CHECK:STDOUT: %T: type = assoc_const_decl T [template] -// CHECK:STDOUT: %.loc8: %.1 = assoc_entity element0, %T [template = constants.%.2] +// CHECK:STDOUT: %.loc8: %.1 = assoc_entity %T, element0 [template = constants.%.2] // CHECK:STDOUT: %F.decl: %F.type.1 = fn_decl @F.1 [template = constants.%F.1] {} {} -// CHECK:STDOUT: %.loc9: %.3 = assoc_entity element1, %F.decl [template = constants.%.4] +// CHECK:STDOUT: %.loc9: %.3 = assoc_entity %F.decl, element1 [template = constants.%.4] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self @@ -113,9 +113,9 @@ var f: ForwardDeclared* = &f_ref.f; // CHECK:STDOUT: interface @ForwardDeclared { // CHECK:STDOUT: %Self: %ForwardDeclared.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self.3] // CHECK:STDOUT: %T: type = assoc_const_decl T [template] -// CHECK:STDOUT: %.loc16: %.5 = assoc_entity element0, %T [template = constants.%.6] +// CHECK:STDOUT: %.loc16: %.5 = assoc_entity %T, element0 [template = constants.%.6] // CHECK:STDOUT: %F.decl: %F.type.2 = fn_decl @F.2 [template = constants.%F.2] {} {} -// CHECK:STDOUT: %.loc17: %.7 = assoc_entity element1, %F.decl [template = constants.%.8] +// CHECK:STDOUT: %.loc17: %.7 = assoc_entity %F.decl, element1 [template = constants.%.8] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self @@ -153,15 +153,15 @@ var f: ForwardDeclared* = &f_ref.f; // CHECK:STDOUT: %UseForwardDeclared.type: type = fn_type @UseForwardDeclared [template] // CHECK:STDOUT: %UseForwardDeclared: %UseForwardDeclared.type = struct_value () [template] // CHECK:STDOUT: %.1: type = assoc_entity_type %Basic.type, type [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, imports.%import_ref.16 [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity imports.%import_ref.16, element0 [template] // CHECK:STDOUT: %F.type.1: type = fn_type @F.1 [template] // CHECK:STDOUT: %.3: type = assoc_entity_type %Basic.type, %F.type.1 [template] -// CHECK:STDOUT: %.4: %.3 = assoc_entity element1, imports.%import_ref.17 [template] +// CHECK:STDOUT: %.4: %.3 = assoc_entity imports.%import_ref.17, element1 [template] // CHECK:STDOUT: %.5: type = assoc_entity_type %ForwardDeclared.type, type [template] -// CHECK:STDOUT: %.6: %.5 = assoc_entity element0, imports.%import_ref.18 [template] +// CHECK:STDOUT: %.6: %.5 = assoc_entity imports.%import_ref.18, element0 [template] // CHECK:STDOUT: %F.type.2: type = fn_type @F.2 [template] // CHECK:STDOUT: %.7: type = assoc_entity_type %ForwardDeclared.type, %F.type.2 [template] -// CHECK:STDOUT: %.8: %.7 = assoc_entity element1, imports.%import_ref.19 [template] +// CHECK:STDOUT: %.8: %.7 = assoc_entity imports.%import_ref.19, element1 [template] // CHECK:STDOUT: %.9: type = ptr_type %ForwardDeclared.type [template] // CHECK:STDOUT: %.10: type = struct_type {.f: %ForwardDeclared.type} [template] // CHECK:STDOUT: } diff --git a/toolchain/check/testdata/interface/no_prelude/self.carbon b/toolchain/check/testdata/interface/no_prelude/self.carbon index 0c6c923bcbb7d..e3f3cae098272 100644 --- a/toolchain/check/testdata/interface/no_prelude/self.carbon +++ b/toolchain/check/testdata/interface/no_prelude/self.carbon @@ -21,7 +21,7 @@ interface UseSelf { // CHECK:STDOUT: %F.type: type = fn_type @F [template] // CHECK:STDOUT: %F: %F.type = struct_value () [template] // CHECK:STDOUT: %.2: type = assoc_entity_type %UseSelf.type, %F.type [template] -// CHECK:STDOUT: %.3: %.2 = assoc_entity element0, @UseSelf.%F.decl [template] +// CHECK:STDOUT: %.3: %.2 = assoc_entity @UseSelf.%F.decl, element0 [template] // CHECK:STDOUT: } // CHECK:STDOUT: // CHECK:STDOUT: file { @@ -50,7 +50,7 @@ interface UseSelf { // CHECK:STDOUT: %return.param: ref @F.%.loc12_14.1 (%.1) = out_param runtime_param1 // CHECK:STDOUT: %return: ref @F.%.loc12_14.1 (%.1) = return_slot %return.param // CHECK:STDOUT: } -// CHECK:STDOUT: %.loc12: %.2 = assoc_entity element0, %F.decl [template = constants.%.3] +// CHECK:STDOUT: %.loc12: %.2 = assoc_entity %F.decl, element0 [template = constants.%.3] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self diff --git a/toolchain/check/testdata/interface/todo_define_not_default.carbon b/toolchain/check/testdata/interface/todo_define_not_default.carbon index 4a1e3d1ebb291..326af74fd0940 100644 --- a/toolchain/check/testdata/interface/todo_define_not_default.carbon +++ b/toolchain/check/testdata/interface/todo_define_not_default.carbon @@ -27,7 +27,7 @@ interface I { // CHECK:STDOUT: %F.type: type = fn_type @F [template] // CHECK:STDOUT: %F: %F.type = struct_value () [template] // CHECK:STDOUT: %.1: type = assoc_entity_type %I.type, %F.type [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @I.%F.decl [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @I.%F.decl, element0 [template] // CHECK:STDOUT: %.3: Core.IntLiteral = int_value 32 [template] // CHECK:STDOUT: %Int.type: type = fn_type @Int [template] // CHECK:STDOUT: %Int: %Int.type = struct_value () [template] @@ -35,11 +35,11 @@ interface I { // CHECK:STDOUT: %G.type: type = fn_type @G [template] // CHECK:STDOUT: %G: %G.type = struct_value () [template] // CHECK:STDOUT: %.4: type = assoc_entity_type %I.type, %G.type [template] -// CHECK:STDOUT: %.5: %.4 = assoc_entity element1, @I.%G.decl [template] +// CHECK:STDOUT: %.5: %.4 = assoc_entity @I.%G.decl, element1 [template] // CHECK:STDOUT: %tuple.type.1: type = tuple_type (type, type) [template] // CHECK:STDOUT: %tuple.type.2: type = tuple_type (%i32, %i32) [template] // CHECK:STDOUT: %.6: type = assoc_entity_type %I.type, type [template] -// CHECK:STDOUT: %.7: %.6 = assoc_entity element2, @I.%T [template] +// CHECK:STDOUT: %.7: %.6 = assoc_entity @I.%T, element2 [template] // CHECK:STDOUT: %.8: Core.IntLiteral = int_value 42 [template] // CHECK:STDOUT: %Convert.type.2: type = fn_type @Convert.1, @ImplicitAs(%i32) [template] // CHECK:STDOUT: %Convert.type.14: type = fn_type @Convert.2, @impl.1(%.3) [template] @@ -49,7 +49,7 @@ interface I { // CHECK:STDOUT: %.34: = specific_function %.33, @Convert.2(%.3) [template] // CHECK:STDOUT: %.35: %i32 = int_value 42 [template] // CHECK:STDOUT: %.36: type = assoc_entity_type %I.type, %i32 [template] -// CHECK:STDOUT: %.37: %.36 = assoc_entity element3, @I.%N [template] +// CHECK:STDOUT: %.37: %.36 = assoc_entity @I.%N, element3 [template] // CHECK:STDOUT: } // CHECK:STDOUT: // CHECK:STDOUT: imports { @@ -73,7 +73,7 @@ interface I { // CHECK:STDOUT: interface @I { // CHECK:STDOUT: %Self: %I.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self.1] // CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {} {} -// CHECK:STDOUT: %.loc13: %.1 = assoc_entity element0, %F.decl [template = constants.%.2] +// CHECK:STDOUT: %.loc13: %.1 = assoc_entity %F.decl, element0 [template = constants.%.2] // CHECK:STDOUT: %G.decl: %G.type = fn_decl @G [template = constants.%G] { // CHECK:STDOUT: %a.patt: %i32 = binding_pattern a // CHECK:STDOUT: %a.param_patt: %i32 = value_param_pattern %a.patt, runtime_param0 @@ -101,7 +101,7 @@ interface I { // CHECK:STDOUT: %return.param: ref %i32 = out_param runtime_param2 // CHECK:STDOUT: %return: ref %i32 = return_slot %return.param // CHECK:STDOUT: } -// CHECK:STDOUT: %.loc14: %.4 = assoc_entity element1, %G.decl [template = constants.%.5] +// CHECK:STDOUT: %.loc14: %.4 = assoc_entity %G.decl, element1 [template = constants.%.5] // CHECK:STDOUT: %.loc18_19: Core.IntLiteral = int_value 32 [template = constants.%.3] // CHECK:STDOUT: %int.make_type_signed.loc18_19: init type = call constants.%Int(%.loc18_19) [template = constants.%i32] // CHECK:STDOUT: %.loc18_24: Core.IntLiteral = int_value 32 [template = constants.%.3] @@ -113,7 +113,7 @@ interface I { // CHECK:STDOUT: %.loc18_28.4: type = converted %int.make_type_signed.loc18_24, %.loc18_28.3 [template = constants.%i32] // CHECK:STDOUT: %.loc18_28.5: type = converted %.loc18_27, constants.%tuple.type.2 [template = constants.%tuple.type.2] // CHECK:STDOUT: %T: type = assoc_const_decl T [template] -// CHECK:STDOUT: %.loc18_28.6: %.6 = assoc_entity element2, %T [template = constants.%.7] +// CHECK:STDOUT: %.loc18_28.6: %.6 = assoc_entity %T, element2 [template = constants.%.7] // CHECK:STDOUT: %.loc19_11.1: Core.IntLiteral = int_value 32 [template = constants.%.3] // CHECK:STDOUT: %int.make_type_signed.loc19: init type = call constants.%Int(%.loc19_11.1) [template = constants.%i32] // CHECK:STDOUT: %.loc19_11.2: type = value_of_initializer %int.make_type_signed.loc19 [template = constants.%i32] @@ -126,7 +126,7 @@ interface I { // CHECK:STDOUT: %.loc19_19.4: %i32 = value_of_initializer %int.convert_checked [template = constants.%.35] // CHECK:STDOUT: %.loc19_19.5: %i32 = converted %.loc19_17, %.loc19_19.4 [template = constants.%.35] // CHECK:STDOUT: %N: %i32 = assoc_const_decl N [template] -// CHECK:STDOUT: %.loc19_19.6: %.36 = assoc_entity element3, %N [template = constants.%.37] +// CHECK:STDOUT: %.loc19_19.6: %.36 = assoc_entity %N, element3 [template = constants.%.37] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self diff --git a/toolchain/check/testdata/let/compile_time_bindings.carbon b/toolchain/check/testdata/let/compile_time_bindings.carbon index 2bbe443443d8b..6935c1381d66d 100644 --- a/toolchain/check/testdata/let/compile_time_bindings.carbon +++ b/toolchain/check/testdata/let/compile_time_bindings.carbon @@ -689,11 +689,11 @@ impl i32 as Empty { // CHECK:STDOUT: %Int: %Int.type = struct_value () [template] // CHECK:STDOUT: %i32: type = int_type signed, %.1 [template] // CHECK:STDOUT: %.2: type = assoc_entity_type %I.type, type [template] -// CHECK:STDOUT: %.3: %.2 = assoc_entity element0, @I.%T [template] +// CHECK:STDOUT: %.3: %.2 = assoc_entity @I.%T, element0 [template] // CHECK:STDOUT: %F.type: type = fn_type @F [template] // CHECK:STDOUT: %F: %F.type = struct_value () [template] // CHECK:STDOUT: %.27: type = assoc_entity_type %I.type, %F.type [template] -// CHECK:STDOUT: %.28: %.27 = assoc_entity element1, @I.%F.decl [template] +// CHECK:STDOUT: %.28: %.27 = assoc_entity @I.%F.decl, element1 [template] // CHECK:STDOUT: } // CHECK:STDOUT: // CHECK:STDOUT: imports { @@ -721,7 +721,7 @@ impl i32 as Empty { // CHECK:STDOUT: %.loc5_21.1: type = value_of_initializer %int.make_type_signed [template = constants.%i32] // CHECK:STDOUT: %.loc5_21.2: type = converted %int.make_type_signed, %.loc5_21.1 [template = constants.%i32] // CHECK:STDOUT: %T: type = assoc_const_decl T [template] -// CHECK:STDOUT: %.loc5_21.3: %.2 = assoc_entity element0, %T [template = constants.%.3] +// CHECK:STDOUT: %.loc5_21.3: %.2 = assoc_entity %T, element0 [template = constants.%.3] // CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] { // CHECK:STDOUT: %return.patt: = return_slot_pattern // CHECK:STDOUT: %return.param_patt: = out_param_pattern %return.patt, runtime_param0 @@ -731,7 +731,7 @@ impl i32 as Empty { // CHECK:STDOUT: %return.param: ref = out_param runtime_param0 // CHECK:STDOUT: %return: ref = return_slot %return.param // CHECK:STDOUT: } -// CHECK:STDOUT: %.loc13: %.27 = assoc_entity element1, %F.decl [template = constants.%.28] +// CHECK:STDOUT: %.loc13: %.27 = assoc_entity %F.decl, element1 [template = constants.%.28] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self diff --git a/toolchain/check/testdata/operators/overloaded/no_prelude/index.carbon b/toolchain/check/testdata/operators/overloaded/no_prelude/index.carbon index faded026022b8..cb991e6cfb3e2 100644 --- a/toolchain/check/testdata/operators/overloaded/no_prelude/index.carbon +++ b/toolchain/check/testdata/operators/overloaded/no_prelude/index.carbon @@ -125,14 +125,14 @@ fn F() { ()[()]; } // CHECK:STDOUT: %At.type.1: type = fn_type @At.1, @IndexWith(%SubscriptType) [symbolic] // CHECK:STDOUT: %At.1: %At.type.1 = struct_value () [symbolic] // CHECK:STDOUT: %.2: type = assoc_entity_type %IndexWith.type.2, %At.type.1 [symbolic] -// CHECK:STDOUT: %.3: %.2 = assoc_entity element0, @IndexWith.%At.decl [symbolic] +// CHECK:STDOUT: %.3: %.2 = assoc_entity @IndexWith.%At.decl, element0 [symbolic] // CHECK:STDOUT: %IndexWith.type.3: type = facet_type <@IndexWith, @IndexWith(%empty_tuple.type)> [template] // CHECK:STDOUT: %At.type.2: type = fn_type @At.2 [template] // CHECK:STDOUT: %At.2: %At.type.2 = struct_value () [template] // CHECK:STDOUT: %At.type.3: type = fn_type @At.1, @IndexWith(%empty_tuple.type) [template] // CHECK:STDOUT: %At.3: %At.type.3 = struct_value () [template] // CHECK:STDOUT: %.4: type = assoc_entity_type %IndexWith.type.3, %At.type.3 [template] -// CHECK:STDOUT: %.5: %.4 = assoc_entity element0, @IndexWith.%At.decl [template] +// CHECK:STDOUT: %.5: %.4 = assoc_entity @IndexWith.%At.decl, element0 [template] // CHECK:STDOUT: %.6: %IndexWith.type.2 = facet_value %empty_tuple.type, %empty_tuple.type [symbolic] // CHECK:STDOUT: %.7: = interface_witness (%At.2) [template] // CHECK:STDOUT: %empty_tuple: %empty_tuple.type = tuple_value () [template] @@ -178,7 +178,7 @@ fn F() { ()[()]; } // CHECK:STDOUT: %At.type: type = fn_type @At.1, @IndexWith(%SubscriptType.loc5_26.2) [symbolic = %At.type (constants.%At.type.1)] // CHECK:STDOUT: %At: @IndexWith.%At.type (%At.type.1) = struct_value () [symbolic = %At (constants.%At.1)] // CHECK:STDOUT: %.loc6_52.2: type = assoc_entity_type @IndexWith.%IndexWith.type (%IndexWith.type.2), @IndexWith.%At.type (%At.type.1) [symbolic = %.loc6_52.2 (constants.%.2)] -// CHECK:STDOUT: %.loc6_52.3: @IndexWith.%.loc6_52.2 (%.2) = assoc_entity element0, %At.decl [symbolic = %.loc6_52.3 (constants.%.3)] +// CHECK:STDOUT: %.loc6_52.3: @IndexWith.%.loc6_52.2 (%.2) = assoc_entity %At.decl, element0 [symbolic = %.loc6_52.3 (constants.%.3)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: %Self.1: @IndexWith.%IndexWith.type (%IndexWith.type.2) = bind_symbolic_name Self, 1 [symbolic = %Self.2 (constants.%Self)] @@ -204,7 +204,7 @@ fn F() { ()[()]; } // CHECK:STDOUT: %return.param: ref %empty_tuple.type = out_param runtime_param2 // CHECK:STDOUT: %return: ref %empty_tuple.type = return_slot %return.param // CHECK:STDOUT: } -// CHECK:STDOUT: %.loc6_52.1: @IndexWith.%.loc6_52.2 (%.2) = assoc_entity element0, %At.decl [symbolic = %.loc6_52.3 (constants.%.3)] +// CHECK:STDOUT: %.loc6_52.1: @IndexWith.%.loc6_52.2 (%.2) = assoc_entity %At.decl, element0 [symbolic = %.loc6_52.3 (constants.%.3)] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self.1 diff --git a/toolchain/check/testdata/packages/implicit_imports_prelude.carbon b/toolchain/check/testdata/packages/implicit_imports_prelude.carbon index ecc2039e8cf2b..0451ce2260813 100644 --- a/toolchain/check/testdata/packages/implicit_imports_prelude.carbon +++ b/toolchain/check/testdata/packages/implicit_imports_prelude.carbon @@ -90,7 +90,7 @@ var b: i32 = a; // CHECK:STDOUT: %Convert.1: %Convert.type.1 = struct_value () [symbolic] // CHECK:STDOUT: %.1: type = facet_access_type %Self.2 [symbolic] // CHECK:STDOUT: %.2: type = assoc_entity_type %ImplicitAs.type.2, %Convert.type.1 [symbolic] -// CHECK:STDOUT: %.3: %.2 = assoc_entity element0, imports.%import_ref.8 [symbolic] +// CHECK:STDOUT: %.3: %.2 = assoc_entity imports.%import_ref.8, element0 [symbolic] // CHECK:STDOUT: %Convert.type.2: type = fn_type @Convert.2, @impl.1(%N) [symbolic] // CHECK:STDOUT: %Convert.2: %Convert.type.2 = struct_value () [symbolic] // CHECK:STDOUT: %.4: = interface_witness (%Convert.2) [symbolic] @@ -107,7 +107,7 @@ var b: i32 = a; // CHECK:STDOUT: %Convert.type.5: type = fn_type @Convert.1, @ImplicitAs(Core.IntLiteral) [template] // CHECK:STDOUT: %Convert.5: %Convert.type.5 = struct_value () [template] // CHECK:STDOUT: %.8: type = assoc_entity_type %ImplicitAs.type.5, %Convert.type.5 [template] -// CHECK:STDOUT: %.9: %.8 = assoc_entity element0, imports.%import_ref.15 [template] +// CHECK:STDOUT: %.9: %.8 = assoc_entity imports.%import_ref.15, element0 [template] // CHECK:STDOUT: %Convert.type.6: type = fn_type @Convert.5, @impl.4(%N) [symbolic] // CHECK:STDOUT: %Convert.6: %Convert.type.6 = struct_value () [symbolic] // CHECK:STDOUT: %.10: = interface_witness (%Convert.6) [symbolic] @@ -119,7 +119,7 @@ var b: i32 = a; // CHECK:STDOUT: %Convert.7: %Convert.type.7 = struct_value () [symbolic] // CHECK:STDOUT: %.11: type = facet_access_type %Self.4 [symbolic] // CHECK:STDOUT: %.12: type = assoc_entity_type %As.type.2, %Convert.type.7 [symbolic] -// CHECK:STDOUT: %.13: %.12 = assoc_entity element0, imports.%import_ref.25 [symbolic] +// CHECK:STDOUT: %.13: %.12 = assoc_entity imports.%import_ref.25, element0 [symbolic] // CHECK:STDOUT: %Convert.type.8: type = fn_type @Convert.7, @impl.5(%N) [symbolic] // CHECK:STDOUT: %Convert.8: %Convert.type.8 = struct_value () [symbolic] // CHECK:STDOUT: %.14: = interface_witness (%Convert.8) [symbolic] @@ -135,7 +135,7 @@ var b: i32 = a; // CHECK:STDOUT: %Convert.type.11: type = fn_type @Convert.6, @As(Core.IntLiteral) [template] // CHECK:STDOUT: %Convert.11: %Convert.type.11 = struct_value () [template] // CHECK:STDOUT: %.18: type = assoc_entity_type %As.type.5, %Convert.type.11 [template] -// CHECK:STDOUT: %.19: %.18 = assoc_entity element0, imports.%import_ref.32 [template] +// CHECK:STDOUT: %.19: %.18 = assoc_entity imports.%import_ref.32, element0 [template] // CHECK:STDOUT: %Convert.type.12: type = fn_type @Convert.10, @impl.8(%N) [symbolic] // CHECK:STDOUT: %Convert.12: %Convert.type.12 = struct_value () [symbolic] // CHECK:STDOUT: %.20: = interface_witness (%Convert.12) [symbolic] @@ -213,7 +213,7 @@ var b: i32 = a; // CHECK:STDOUT: %Convert.type: type = fn_type @Convert.1, @ImplicitAs(%Dest) [symbolic = %Convert.type (constants.%Convert.type.1)] // CHECK:STDOUT: %Convert: @ImplicitAs.%Convert.type (%Convert.type.1) = struct_value () [symbolic = %Convert (constants.%Convert.1)] // CHECK:STDOUT: %.1: type = assoc_entity_type @ImplicitAs.%ImplicitAs.type (%ImplicitAs.type.2), @ImplicitAs.%Convert.type (%Convert.type.1) [symbolic = %.1 (constants.%.2)] -// CHECK:STDOUT: %.2: @ImplicitAs.%.1 (%.2) = assoc_entity element0, imports.%import_ref.8 [symbolic = %.2 (constants.%.3)] +// CHECK:STDOUT: %.2: @ImplicitAs.%.1 (%.2) = assoc_entity imports.%import_ref.8, element0 [symbolic = %.2 (constants.%.3)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: !members: @@ -233,7 +233,7 @@ var b: i32 = a; // CHECK:STDOUT: %Convert.type: type = fn_type @Convert.6, @As(%Dest) [symbolic = %Convert.type (constants.%Convert.type.7)] // CHECK:STDOUT: %Convert: @As.%Convert.type (%Convert.type.7) = struct_value () [symbolic = %Convert (constants.%Convert.7)] // CHECK:STDOUT: %.1: type = assoc_entity_type @As.%As.type (%As.type.2), @As.%Convert.type (%Convert.type.7) [symbolic = %.1 (constants.%.12)] -// CHECK:STDOUT: %.2: @As.%.1 (%.12) = assoc_entity element0, imports.%import_ref.25 [symbolic = %.2 (constants.%.13)] +// CHECK:STDOUT: %.2: @As.%.1 (%.12) = assoc_entity imports.%import_ref.25, element0 [symbolic = %.2 (constants.%.13)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: !members: diff --git a/toolchain/check/testdata/pointer/import.carbon b/toolchain/check/testdata/pointer/import.carbon index 857a544953f6a..4b13ac24fde67 100644 --- a/toolchain/check/testdata/pointer/import.carbon +++ b/toolchain/check/testdata/pointer/import.carbon @@ -101,7 +101,7 @@ var a: i32* = a_ref; // CHECK:STDOUT: %Convert.1: %Convert.type.1 = struct_value () [symbolic] // CHECK:STDOUT: %.1: type = facet_access_type %Self.2 [symbolic] // CHECK:STDOUT: %.2: type = assoc_entity_type %ImplicitAs.type.2, %Convert.type.1 [symbolic] -// CHECK:STDOUT: %.3: %.2 = assoc_entity element0, imports.%import_ref.9 [symbolic] +// CHECK:STDOUT: %.3: %.2 = assoc_entity imports.%import_ref.9, element0 [symbolic] // CHECK:STDOUT: %Convert.type.2: type = fn_type @Convert.2, @impl.1(%N) [symbolic] // CHECK:STDOUT: %Convert.2: %Convert.type.2 = struct_value () [symbolic] // CHECK:STDOUT: %.4: = interface_witness (%Convert.2) [symbolic] @@ -118,7 +118,7 @@ var a: i32* = a_ref; // CHECK:STDOUT: %Convert.type.5: type = fn_type @Convert.1, @ImplicitAs(Core.IntLiteral) [template] // CHECK:STDOUT: %Convert.5: %Convert.type.5 = struct_value () [template] // CHECK:STDOUT: %.8: type = assoc_entity_type %ImplicitAs.type.5, %Convert.type.5 [template] -// CHECK:STDOUT: %.9: %.8 = assoc_entity element0, imports.%import_ref.16 [template] +// CHECK:STDOUT: %.9: %.8 = assoc_entity imports.%import_ref.16, element0 [template] // CHECK:STDOUT: %Convert.type.6: type = fn_type @Convert.5, @impl.4(%N) [symbolic] // CHECK:STDOUT: %Convert.6: %Convert.type.6 = struct_value () [symbolic] // CHECK:STDOUT: %.10: = interface_witness (%Convert.6) [symbolic] @@ -130,7 +130,7 @@ var a: i32* = a_ref; // CHECK:STDOUT: %Convert.7: %Convert.type.7 = struct_value () [symbolic] // CHECK:STDOUT: %.11: type = facet_access_type %Self.4 [symbolic] // CHECK:STDOUT: %.12: type = assoc_entity_type %As.type.2, %Convert.type.7 [symbolic] -// CHECK:STDOUT: %.13: %.12 = assoc_entity element0, imports.%import_ref.26 [symbolic] +// CHECK:STDOUT: %.13: %.12 = assoc_entity imports.%import_ref.26, element0 [symbolic] // CHECK:STDOUT: %Convert.type.8: type = fn_type @Convert.7, @impl.5(%N) [symbolic] // CHECK:STDOUT: %Convert.8: %Convert.type.8 = struct_value () [symbolic] // CHECK:STDOUT: %.14: = interface_witness (%Convert.8) [symbolic] @@ -146,7 +146,7 @@ var a: i32* = a_ref; // CHECK:STDOUT: %Convert.type.11: type = fn_type @Convert.6, @As(Core.IntLiteral) [template] // CHECK:STDOUT: %Convert.11: %Convert.type.11 = struct_value () [template] // CHECK:STDOUT: %.18: type = assoc_entity_type %As.type.5, %Convert.type.11 [template] -// CHECK:STDOUT: %.19: %.18 = assoc_entity element0, imports.%import_ref.33 [template] +// CHECK:STDOUT: %.19: %.18 = assoc_entity imports.%import_ref.33, element0 [template] // CHECK:STDOUT: %Convert.type.12: type = fn_type @Convert.10, @impl.8(%N) [symbolic] // CHECK:STDOUT: %Convert.12: %Convert.type.12 = struct_value () [symbolic] // CHECK:STDOUT: %.20: = interface_witness (%Convert.12) [symbolic] @@ -228,7 +228,7 @@ var a: i32* = a_ref; // CHECK:STDOUT: %Convert.type: type = fn_type @Convert.1, @ImplicitAs(%Dest) [symbolic = %Convert.type (constants.%Convert.type.1)] // CHECK:STDOUT: %Convert: @ImplicitAs.%Convert.type (%Convert.type.1) = struct_value () [symbolic = %Convert (constants.%Convert.1)] // CHECK:STDOUT: %.1: type = assoc_entity_type @ImplicitAs.%ImplicitAs.type (%ImplicitAs.type.2), @ImplicitAs.%Convert.type (%Convert.type.1) [symbolic = %.1 (constants.%.2)] -// CHECK:STDOUT: %.2: @ImplicitAs.%.1 (%.2) = assoc_entity element0, imports.%import_ref.9 [symbolic = %.2 (constants.%.3)] +// CHECK:STDOUT: %.2: @ImplicitAs.%.1 (%.2) = assoc_entity imports.%import_ref.9, element0 [symbolic = %.2 (constants.%.3)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: !members: @@ -248,7 +248,7 @@ var a: i32* = a_ref; // CHECK:STDOUT: %Convert.type: type = fn_type @Convert.6, @As(%Dest) [symbolic = %Convert.type (constants.%Convert.type.7)] // CHECK:STDOUT: %Convert: @As.%Convert.type (%Convert.type.7) = struct_value () [symbolic = %Convert (constants.%Convert.7)] // CHECK:STDOUT: %.1: type = assoc_entity_type @As.%As.type (%As.type.2), @As.%Convert.type (%Convert.type.7) [symbolic = %.1 (constants.%.12)] -// CHECK:STDOUT: %.2: @As.%.1 (%.12) = assoc_entity element0, imports.%import_ref.26 [symbolic = %.2 (constants.%.13)] +// CHECK:STDOUT: %.2: @As.%.1 (%.12) = assoc_entity imports.%import_ref.26, element0 [symbolic = %.2 (constants.%.13)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: !members: diff --git a/toolchain/check/testdata/return/no_prelude/import_convert_function.carbon b/toolchain/check/testdata/return/no_prelude/import_convert_function.carbon index 157c31ac6652c..0c4d2c96eac07 100644 --- a/toolchain/check/testdata/return/no_prelude/import_convert_function.carbon +++ b/toolchain/check/testdata/return/no_prelude/import_convert_function.carbon @@ -79,7 +79,7 @@ fn F0(n: i32) -> P.D { // CHECK:STDOUT: %Convert.type.1: type = fn_type @Convert.1, @ImplicitAs(%T) [symbolic] // CHECK:STDOUT: %Convert.1: %Convert.type.1 = struct_value () [symbolic] // CHECK:STDOUT: %.2: type = assoc_entity_type %ImplicitAs.type.2, %Convert.type.1 [symbolic] -// CHECK:STDOUT: %.3: %.2 = assoc_entity element0, @ImplicitAs.%Convert.decl [symbolic] +// CHECK:STDOUT: %.3: %.2 = assoc_entity @ImplicitAs.%Convert.decl, element0 [symbolic] // CHECK:STDOUT: %.4: Core.IntLiteral = int_value 32 [template] // CHECK:STDOUT: %i32: type = int_type signed, %.4 [template] // CHECK:STDOUT: %ImplicitAs.type.3: type = facet_type <@ImplicitAs, @ImplicitAs(%i32)> [template] @@ -88,7 +88,7 @@ fn F0(n: i32) -> P.D { // CHECK:STDOUT: %Convert.type.3: type = fn_type @Convert.1, @ImplicitAs(%i32) [template] // CHECK:STDOUT: %Convert.3: %Convert.type.3 = struct_value () [template] // CHECK:STDOUT: %.5: type = assoc_entity_type %ImplicitAs.type.3, %Convert.type.3 [template] -// CHECK:STDOUT: %.6: %.5 = assoc_entity element0, @ImplicitAs.%Convert.decl [template] +// CHECK:STDOUT: %.6: %.5 = assoc_entity @ImplicitAs.%Convert.decl, element0 [template] // CHECK:STDOUT: %.7: %ImplicitAs.type.2 = facet_value Core.IntLiteral, Core.IntLiteral [symbolic] // CHECK:STDOUT: %.8: = interface_witness (%Convert.2) [template] // CHECK:STDOUT: } @@ -152,7 +152,7 @@ fn F0(n: i32) -> P.D { // CHECK:STDOUT: %Convert.type: type = fn_type @Convert.1, @ImplicitAs(%T.loc8_22.2) [symbolic = %Convert.type (constants.%Convert.type.1)] // CHECK:STDOUT: %Convert: @ImplicitAs.%Convert.type (%Convert.type.1) = struct_value () [symbolic = %Convert (constants.%Convert.1)] // CHECK:STDOUT: %.loc9_32.2: type = assoc_entity_type @ImplicitAs.%ImplicitAs.type (%ImplicitAs.type.2), @ImplicitAs.%Convert.type (%Convert.type.1) [symbolic = %.loc9_32.2 (constants.%.2)] -// CHECK:STDOUT: %.loc9_32.3: @ImplicitAs.%.loc9_32.2 (%.2) = assoc_entity element0, %Convert.decl [symbolic = %.loc9_32.3 (constants.%.3)] +// CHECK:STDOUT: %.loc9_32.3: @ImplicitAs.%.loc9_32.2 (%.2) = assoc_entity %Convert.decl, element0 [symbolic = %.loc9_32.3 (constants.%.3)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: %Self.1: @ImplicitAs.%ImplicitAs.type (%ImplicitAs.type.2) = bind_symbolic_name Self, 1 [symbolic = %Self.2 (constants.%Self)] @@ -172,7 +172,7 @@ fn F0(n: i32) -> P.D { // CHECK:STDOUT: %return.param: ref @Convert.1.%T (%T) = out_param runtime_param1 // CHECK:STDOUT: %return: ref @Convert.1.%T (%T) = return_slot %return.param // CHECK:STDOUT: } -// CHECK:STDOUT: %.loc9_32.1: @ImplicitAs.%.loc9_32.2 (%.2) = assoc_entity element0, %Convert.decl [symbolic = %.loc9_32.3 (constants.%.3)] +// CHECK:STDOUT: %.loc9_32.1: @ImplicitAs.%.loc9_32.2 (%.2) = assoc_entity %Convert.decl, element0 [symbolic = %.loc9_32.3 (constants.%.3)] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self.1 @@ -295,14 +295,14 @@ fn F0(n: i32) -> P.D { // CHECK:STDOUT: %Convert.1: %Convert.type.1 = struct_value () [symbolic] // CHECK:STDOUT: %.10: type = facet_access_type %Self.2 [symbolic] // CHECK:STDOUT: %.11: type = assoc_entity_type %ImplicitAs.type.2, %Convert.type.1 [symbolic] -// CHECK:STDOUT: %.12: %.11 = assoc_entity element0, imports.%import_ref.6 [symbolic] +// CHECK:STDOUT: %.12: %.11 = assoc_entity imports.%import_ref.6, element0 [symbolic] // CHECK:STDOUT: %.13: type = facet_access_type %Self.1 [symbolic] // CHECK:STDOUT: %ImplicitAs.type.3: type = facet_type <@ImplicitAs, @ImplicitAs(%i32)> [template] // CHECK:STDOUT: %Convert.type.2: type = fn_type @Convert.1, @ImplicitAs(%i32) [template] // CHECK:STDOUT: %Convert.2: %Convert.type.2 = struct_value () [template] // CHECK:STDOUT: %.14: type = assoc_entity_type %ImplicitAs.type.3, %Convert.type.2 [template] -// CHECK:STDOUT: %.15: %.14 = assoc_entity element0, imports.%import_ref.6 [template] -// CHECK:STDOUT: %.16: %.11 = assoc_entity element0, imports.%import_ref.7 [symbolic] +// CHECK:STDOUT: %.15: %.14 = assoc_entity imports.%import_ref.6, element0 [template] +// CHECK:STDOUT: %.16: %.11 = assoc_entity imports.%import_ref.7, element0 [symbolic] // CHECK:STDOUT: %Convert.type.3: type = fn_type @Convert.2 [template] // CHECK:STDOUT: %Convert.3: %Convert.type.3 = struct_value () [template] // CHECK:STDOUT: %.17: = interface_witness (%Convert.3) [template] @@ -316,7 +316,7 @@ fn F0(n: i32) -> P.D { // CHECK:STDOUT: %Convert.type.5: type = fn_type @Convert.1, @ImplicitAs(%D) [template] // CHECK:STDOUT: %Convert.5: %Convert.type.5 = struct_value () [template] // CHECK:STDOUT: %.20: type = assoc_entity_type %ImplicitAs.type.4, %Convert.type.5 [template] -// CHECK:STDOUT: %.21: %.20 = assoc_entity element0, imports.%import_ref.6 [template] +// CHECK:STDOUT: %.21: %.20 = assoc_entity imports.%import_ref.6, element0 [template] // CHECK:STDOUT: %.22: %ImplicitAs.type.2 = facet_value %C.3, %C.3 [symbolic] // CHECK:STDOUT: %.23: = interface_witness (%Convert.4) [template] // CHECK:STDOUT: %.25: Core.IntLiteral = int_value 1 [template] @@ -545,7 +545,7 @@ fn F0(n: i32) -> P.D { // CHECK:STDOUT: %Convert.type: type = fn_type @Convert.1, @ImplicitAs(%T) [symbolic = %Convert.type (constants.%Convert.type.1)] // CHECK:STDOUT: %Convert: @ImplicitAs.%Convert.type (%Convert.type.1) = struct_value () [symbolic = %Convert (constants.%Convert.1)] // CHECK:STDOUT: %.1: type = assoc_entity_type @ImplicitAs.%ImplicitAs.type (%ImplicitAs.type.2), @ImplicitAs.%Convert.type (%Convert.type.1) [symbolic = %.1 (constants.%.11)] -// CHECK:STDOUT: %.2: @ImplicitAs.%.1 (%.11) = assoc_entity element0, imports.%import_ref.6 [symbolic = %.2 (constants.%.12)] +// CHECK:STDOUT: %.2: @ImplicitAs.%.1 (%.11) = assoc_entity imports.%import_ref.6, element0 [symbolic = %.2 (constants.%.12)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: !members: @@ -1051,14 +1051,14 @@ fn F0(n: i32) -> P.D { // CHECK:STDOUT: %Convert.1: %Convert.type.1 = struct_value () [symbolic] // CHECK:STDOUT: %.9: type = facet_access_type %Self.2 [symbolic] // CHECK:STDOUT: %.10: type = assoc_entity_type %ImplicitAs.type.2, %Convert.type.1 [symbolic] -// CHECK:STDOUT: %.11: %.10 = assoc_entity element0, imports.%import_ref.12 [symbolic] +// CHECK:STDOUT: %.11: %.10 = assoc_entity imports.%import_ref.12, element0 [symbolic] // CHECK:STDOUT: %.12: type = facet_access_type %Self.1 [symbolic] // CHECK:STDOUT: %ImplicitAs.type.3: type = facet_type <@ImplicitAs, @ImplicitAs(%i32)> [template] // CHECK:STDOUT: %Convert.type.2: type = fn_type @Convert.1, @ImplicitAs(%i32) [template] // CHECK:STDOUT: %Convert.2: %Convert.type.2 = struct_value () [template] // CHECK:STDOUT: %.13: type = assoc_entity_type %ImplicitAs.type.3, %Convert.type.2 [template] -// CHECK:STDOUT: %.14: %.13 = assoc_entity element0, imports.%import_ref.12 [template] -// CHECK:STDOUT: %.15: %.10 = assoc_entity element0, imports.%import_ref.13 [symbolic] +// CHECK:STDOUT: %.14: %.13 = assoc_entity imports.%import_ref.12, element0 [template] +// CHECK:STDOUT: %.15: %.10 = assoc_entity imports.%import_ref.13, element0 [symbolic] // CHECK:STDOUT: %Convert.type.3: type = fn_type @Convert.2 [template] // CHECK:STDOUT: %Convert.3: %Convert.type.3 = struct_value () [template] // CHECK:STDOUT: %.16: = interface_witness (%Convert.3) [template] @@ -1070,7 +1070,7 @@ fn F0(n: i32) -> P.D { // CHECK:STDOUT: %Convert.type.4: type = fn_type @Convert.1, @ImplicitAs(%D) [template] // CHECK:STDOUT: %Convert.4: %Convert.type.4 = struct_value () [template] // CHECK:STDOUT: %.20: type = assoc_entity_type %ImplicitAs.type.4, %Convert.type.4 [template] -// CHECK:STDOUT: %.21: %.20 = assoc_entity element0, imports.%import_ref.12 [template] +// CHECK:STDOUT: %.21: %.20 = assoc_entity imports.%import_ref.12, element0 [template] // CHECK:STDOUT: %.22: %i32 = int_value 1 [template] // CHECK:STDOUT: %C.4: type = class_type @C, @C(%.22) [template] // CHECK:STDOUT: %.23: %i32 = int_value 2 [template] @@ -1223,7 +1223,7 @@ fn F0(n: i32) -> P.D { // CHECK:STDOUT: %Convert.type: type = fn_type @Convert.1, @ImplicitAs(%T) [symbolic = %Convert.type (constants.%Convert.type.1)] // CHECK:STDOUT: %Convert: @ImplicitAs.%Convert.type (%Convert.type.1) = struct_value () [symbolic = %Convert (constants.%Convert.1)] // CHECK:STDOUT: %.1: type = assoc_entity_type @ImplicitAs.%ImplicitAs.type (%ImplicitAs.type.2), @ImplicitAs.%Convert.type (%Convert.type.1) [symbolic = %.1 (constants.%.10)] -// CHECK:STDOUT: %.2: @ImplicitAs.%.1 (%.10) = assoc_entity element0, imports.%import_ref.12 [symbolic = %.2 (constants.%.11)] +// CHECK:STDOUT: %.2: @ImplicitAs.%.1 (%.10) = assoc_entity imports.%import_ref.12, element0 [symbolic = %.2 (constants.%.11)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: !members: diff --git a/toolchain/check/testdata/struct/import.carbon b/toolchain/check/testdata/struct/import.carbon index b7bb4b14f81e0..f0637f452a641 100644 --- a/toolchain/check/testdata/struct/import.carbon +++ b/toolchain/check/testdata/struct/import.carbon @@ -281,7 +281,7 @@ var c_bad: C({.a = 3, .b = 4}) = F(); // CHECK:STDOUT: %Convert.1: %Convert.type.1 = struct_value () [symbolic] // CHECK:STDOUT: %.1: type = facet_access_type %Self.2 [symbolic] // CHECK:STDOUT: %.2: type = assoc_entity_type %ImplicitAs.type.2, %Convert.type.1 [symbolic] -// CHECK:STDOUT: %.3: %.2 = assoc_entity element0, imports.%import_ref.11 [symbolic] +// CHECK:STDOUT: %.3: %.2 = assoc_entity imports.%import_ref.11, element0 [symbolic] // CHECK:STDOUT: %Convert.type.2: type = fn_type @Convert.2, @impl.1(%N) [symbolic] // CHECK:STDOUT: %Convert.2: %Convert.type.2 = struct_value () [symbolic] // CHECK:STDOUT: %.4: = interface_witness (%Convert.2) [symbolic] @@ -298,7 +298,7 @@ var c_bad: C({.a = 3, .b = 4}) = F(); // CHECK:STDOUT: %Convert.type.5: type = fn_type @Convert.1, @ImplicitAs(Core.IntLiteral) [template] // CHECK:STDOUT: %Convert.5: %Convert.type.5 = struct_value () [template] // CHECK:STDOUT: %.8: type = assoc_entity_type %ImplicitAs.type.5, %Convert.type.5 [template] -// CHECK:STDOUT: %.9: %.8 = assoc_entity element0, imports.%import_ref.18 [template] +// CHECK:STDOUT: %.9: %.8 = assoc_entity imports.%import_ref.18, element0 [template] // CHECK:STDOUT: %Convert.type.6: type = fn_type @Convert.5, @impl.4(%N) [symbolic] // CHECK:STDOUT: %Convert.6: %Convert.type.6 = struct_value () [symbolic] // CHECK:STDOUT: %.10: = interface_witness (%Convert.6) [symbolic] @@ -310,7 +310,7 @@ var c_bad: C({.a = 3, .b = 4}) = F(); // CHECK:STDOUT: %Convert.7: %Convert.type.7 = struct_value () [symbolic] // CHECK:STDOUT: %.11: type = facet_access_type %Self.4 [symbolic] // CHECK:STDOUT: %.12: type = assoc_entity_type %As.type.2, %Convert.type.7 [symbolic] -// CHECK:STDOUT: %.13: %.12 = assoc_entity element0, imports.%import_ref.28 [symbolic] +// CHECK:STDOUT: %.13: %.12 = assoc_entity imports.%import_ref.28, element0 [symbolic] // CHECK:STDOUT: %Convert.type.8: type = fn_type @Convert.7, @impl.5(%N) [symbolic] // CHECK:STDOUT: %Convert.8: %Convert.type.8 = struct_value () [symbolic] // CHECK:STDOUT: %.14: = interface_witness (%Convert.8) [symbolic] @@ -326,7 +326,7 @@ var c_bad: C({.a = 3, .b = 4}) = F(); // CHECK:STDOUT: %Convert.type.11: type = fn_type @Convert.6, @As(Core.IntLiteral) [template] // CHECK:STDOUT: %Convert.11: %Convert.type.11 = struct_value () [template] // CHECK:STDOUT: %.18: type = assoc_entity_type %As.type.5, %Convert.type.11 [template] -// CHECK:STDOUT: %.19: %.18 = assoc_entity element0, imports.%import_ref.35 [template] +// CHECK:STDOUT: %.19: %.18 = assoc_entity imports.%import_ref.35, element0 [template] // CHECK:STDOUT: %Convert.type.12: type = fn_type @Convert.10, @impl.8(%N) [symbolic] // CHECK:STDOUT: %Convert.12: %Convert.type.12 = struct_value () [symbolic] // CHECK:STDOUT: %.20: = interface_witness (%Convert.12) [symbolic] @@ -351,8 +351,8 @@ var c_bad: C({.a = 3, .b = 4}) = F(); // CHECK:STDOUT: %Convert.type.13: type = fn_type @Convert.1, @ImplicitAs(%i32) [template] // CHECK:STDOUT: %Convert.13: %Convert.type.13 = struct_value () [template] // CHECK:STDOUT: %.35: type = assoc_entity_type %ImplicitAs.type.6, %Convert.type.13 [template] -// CHECK:STDOUT: %.36: %.35 = assoc_entity element0, imports.%import_ref.11 [template] -// CHECK:STDOUT: %.37: %.2 = assoc_entity element0, imports.%import_ref.42 [symbolic] +// CHECK:STDOUT: %.36: %.35 = assoc_entity imports.%import_ref.11, element0 [template] +// CHECK:STDOUT: %.37: %.2 = assoc_entity imports.%import_ref.42, element0 [symbolic] // CHECK:STDOUT: %Convert.type.14: type = fn_type @Convert.2, @impl.1(%.21) [template] // CHECK:STDOUT: %Convert.14: %Convert.type.14 = struct_value () [template] // CHECK:STDOUT: %.38: = interface_witness (%Convert.14) [template] @@ -486,7 +486,7 @@ var c_bad: C({.a = 3, .b = 4}) = F(); // CHECK:STDOUT: %Convert.type: type = fn_type @Convert.1, @ImplicitAs(%Dest) [symbolic = %Convert.type (constants.%Convert.type.1)] // CHECK:STDOUT: %Convert: @ImplicitAs.%Convert.type (%Convert.type.1) = struct_value () [symbolic = %Convert (constants.%Convert.1)] // CHECK:STDOUT: %.1: type = assoc_entity_type @ImplicitAs.%ImplicitAs.type (%ImplicitAs.type.2), @ImplicitAs.%Convert.type (%Convert.type.1) [symbolic = %.1 (constants.%.2)] -// CHECK:STDOUT: %.2: @ImplicitAs.%.1 (%.2) = assoc_entity element0, imports.%import_ref.11 [symbolic = %.2 (constants.%.3)] +// CHECK:STDOUT: %.2: @ImplicitAs.%.1 (%.2) = assoc_entity imports.%import_ref.11, element0 [symbolic = %.2 (constants.%.3)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: !members: @@ -506,7 +506,7 @@ var c_bad: C({.a = 3, .b = 4}) = F(); // CHECK:STDOUT: %Convert.type: type = fn_type @Convert.6, @As(%Dest) [symbolic = %Convert.type (constants.%Convert.type.7)] // CHECK:STDOUT: %Convert: @As.%Convert.type (%Convert.type.7) = struct_value () [symbolic = %Convert (constants.%Convert.7)] // CHECK:STDOUT: %.1: type = assoc_entity_type @As.%As.type (%As.type.2), @As.%Convert.type (%Convert.type.7) [symbolic = %.1 (constants.%.12)] -// CHECK:STDOUT: %.2: @As.%.1 (%.12) = assoc_entity element0, imports.%import_ref.28 [symbolic = %.2 (constants.%.13)] +// CHECK:STDOUT: %.2: @As.%.1 (%.12) = assoc_entity imports.%import_ref.28, element0 [symbolic = %.2 (constants.%.13)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: !members: @@ -1104,7 +1104,7 @@ var c_bad: C({.a = 3, .b = 4}) = F(); // CHECK:STDOUT: %Convert.1: %Convert.type.1 = struct_value () [symbolic] // CHECK:STDOUT: %.1: type = facet_access_type %Self.2 [symbolic] // CHECK:STDOUT: %.2: type = assoc_entity_type %ImplicitAs.type.2, %Convert.type.1 [symbolic] -// CHECK:STDOUT: %.3: %.2 = assoc_entity element0, imports.%import_ref.11 [symbolic] +// CHECK:STDOUT: %.3: %.2 = assoc_entity imports.%import_ref.11, element0 [symbolic] // CHECK:STDOUT: %Convert.type.2: type = fn_type @Convert.2, @impl.1(%N) [symbolic] // CHECK:STDOUT: %Convert.2: %Convert.type.2 = struct_value () [symbolic] // CHECK:STDOUT: %.4: = interface_witness (%Convert.2) [symbolic] @@ -1121,7 +1121,7 @@ var c_bad: C({.a = 3, .b = 4}) = F(); // CHECK:STDOUT: %Convert.type.5: type = fn_type @Convert.1, @ImplicitAs(Core.IntLiteral) [template] // CHECK:STDOUT: %Convert.5: %Convert.type.5 = struct_value () [template] // CHECK:STDOUT: %.8: type = assoc_entity_type %ImplicitAs.type.5, %Convert.type.5 [template] -// CHECK:STDOUT: %.9: %.8 = assoc_entity element0, imports.%import_ref.18 [template] +// CHECK:STDOUT: %.9: %.8 = assoc_entity imports.%import_ref.18, element0 [template] // CHECK:STDOUT: %Convert.type.6: type = fn_type @Convert.5, @impl.4(%N) [symbolic] // CHECK:STDOUT: %Convert.6: %Convert.type.6 = struct_value () [symbolic] // CHECK:STDOUT: %.10: = interface_witness (%Convert.6) [symbolic] @@ -1133,7 +1133,7 @@ var c_bad: C({.a = 3, .b = 4}) = F(); // CHECK:STDOUT: %Convert.7: %Convert.type.7 = struct_value () [symbolic] // CHECK:STDOUT: %.11: type = facet_access_type %Self.4 [symbolic] // CHECK:STDOUT: %.12: type = assoc_entity_type %As.type.2, %Convert.type.7 [symbolic] -// CHECK:STDOUT: %.13: %.12 = assoc_entity element0, imports.%import_ref.28 [symbolic] +// CHECK:STDOUT: %.13: %.12 = assoc_entity imports.%import_ref.28, element0 [symbolic] // CHECK:STDOUT: %Convert.type.8: type = fn_type @Convert.7, @impl.5(%N) [symbolic] // CHECK:STDOUT: %Convert.8: %Convert.type.8 = struct_value () [symbolic] // CHECK:STDOUT: %.14: = interface_witness (%Convert.8) [symbolic] @@ -1149,7 +1149,7 @@ var c_bad: C({.a = 3, .b = 4}) = F(); // CHECK:STDOUT: %Convert.type.11: type = fn_type @Convert.6, @As(Core.IntLiteral) [template] // CHECK:STDOUT: %Convert.11: %Convert.type.11 = struct_value () [template] // CHECK:STDOUT: %.18: type = assoc_entity_type %As.type.5, %Convert.type.11 [template] -// CHECK:STDOUT: %.19: %.18 = assoc_entity element0, imports.%import_ref.35 [template] +// CHECK:STDOUT: %.19: %.18 = assoc_entity imports.%import_ref.35, element0 [template] // CHECK:STDOUT: %Convert.type.12: type = fn_type @Convert.10, @impl.8(%N) [symbolic] // CHECK:STDOUT: %Convert.12: %Convert.type.12 = struct_value () [symbolic] // CHECK:STDOUT: %.20: = interface_witness (%Convert.12) [symbolic] @@ -1245,7 +1245,7 @@ var c_bad: C({.a = 3, .b = 4}) = F(); // CHECK:STDOUT: %Convert.type: type = fn_type @Convert.1, @ImplicitAs(%Dest) [symbolic = %Convert.type (constants.%Convert.type.1)] // CHECK:STDOUT: %Convert: @ImplicitAs.%Convert.type (%Convert.type.1) = struct_value () [symbolic = %Convert (constants.%Convert.1)] // CHECK:STDOUT: %.1: type = assoc_entity_type @ImplicitAs.%ImplicitAs.type (%ImplicitAs.type.2), @ImplicitAs.%Convert.type (%Convert.type.1) [symbolic = %.1 (constants.%.2)] -// CHECK:STDOUT: %.2: @ImplicitAs.%.1 (%.2) = assoc_entity element0, imports.%import_ref.11 [symbolic = %.2 (constants.%.3)] +// CHECK:STDOUT: %.2: @ImplicitAs.%.1 (%.2) = assoc_entity imports.%import_ref.11, element0 [symbolic = %.2 (constants.%.3)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: !members: @@ -1265,7 +1265,7 @@ var c_bad: C({.a = 3, .b = 4}) = F(); // CHECK:STDOUT: %Convert.type: type = fn_type @Convert.6, @As(%Dest) [symbolic = %Convert.type (constants.%Convert.type.7)] // CHECK:STDOUT: %Convert: @As.%Convert.type (%Convert.type.7) = struct_value () [symbolic = %Convert (constants.%Convert.7)] // CHECK:STDOUT: %.1: type = assoc_entity_type @As.%As.type (%As.type.2), @As.%Convert.type (%Convert.type.7) [symbolic = %.1 (constants.%.12)] -// CHECK:STDOUT: %.2: @As.%.1 (%.12) = assoc_entity element0, imports.%import_ref.28 [symbolic = %.2 (constants.%.13)] +// CHECK:STDOUT: %.2: @As.%.1 (%.12) = assoc_entity imports.%import_ref.28, element0 [symbolic = %.2 (constants.%.13)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: !members: @@ -1802,7 +1802,7 @@ var c_bad: C({.a = 3, .b = 4}) = F(); // CHECK:STDOUT: %Convert.1: %Convert.type.1 = struct_value () [symbolic] // CHECK:STDOUT: %.1: type = facet_access_type %Self.2 [symbolic] // CHECK:STDOUT: %.2: type = assoc_entity_type %ImplicitAs.type.2, %Convert.type.1 [symbolic] -// CHECK:STDOUT: %.3: %.2 = assoc_entity element0, imports.%import_ref.11 [symbolic] +// CHECK:STDOUT: %.3: %.2 = assoc_entity imports.%import_ref.11, element0 [symbolic] // CHECK:STDOUT: %Convert.type.2: type = fn_type @Convert.2, @impl.1(%N) [symbolic] // CHECK:STDOUT: %Convert.2: %Convert.type.2 = struct_value () [symbolic] // CHECK:STDOUT: %.4: = interface_witness (%Convert.2) [symbolic] @@ -1819,7 +1819,7 @@ var c_bad: C({.a = 3, .b = 4}) = F(); // CHECK:STDOUT: %Convert.type.5: type = fn_type @Convert.1, @ImplicitAs(Core.IntLiteral) [template] // CHECK:STDOUT: %Convert.5: %Convert.type.5 = struct_value () [template] // CHECK:STDOUT: %.8: type = assoc_entity_type %ImplicitAs.type.5, %Convert.type.5 [template] -// CHECK:STDOUT: %.9: %.8 = assoc_entity element0, imports.%import_ref.18 [template] +// CHECK:STDOUT: %.9: %.8 = assoc_entity imports.%import_ref.18, element0 [template] // CHECK:STDOUT: %Convert.type.6: type = fn_type @Convert.5, @impl.4(%N) [symbolic] // CHECK:STDOUT: %Convert.6: %Convert.type.6 = struct_value () [symbolic] // CHECK:STDOUT: %.10: = interface_witness (%Convert.6) [symbolic] @@ -1831,7 +1831,7 @@ var c_bad: C({.a = 3, .b = 4}) = F(); // CHECK:STDOUT: %Convert.7: %Convert.type.7 = struct_value () [symbolic] // CHECK:STDOUT: %.11: type = facet_access_type %Self.4 [symbolic] // CHECK:STDOUT: %.12: type = assoc_entity_type %As.type.2, %Convert.type.7 [symbolic] -// CHECK:STDOUT: %.13: %.12 = assoc_entity element0, imports.%import_ref.28 [symbolic] +// CHECK:STDOUT: %.13: %.12 = assoc_entity imports.%import_ref.28, element0 [symbolic] // CHECK:STDOUT: %Convert.type.8: type = fn_type @Convert.7, @impl.5(%N) [symbolic] // CHECK:STDOUT: %Convert.8: %Convert.type.8 = struct_value () [symbolic] // CHECK:STDOUT: %.14: = interface_witness (%Convert.8) [symbolic] @@ -1847,7 +1847,7 @@ var c_bad: C({.a = 3, .b = 4}) = F(); // CHECK:STDOUT: %Convert.type.11: type = fn_type @Convert.6, @As(Core.IntLiteral) [template] // CHECK:STDOUT: %Convert.11: %Convert.type.11 = struct_value () [template] // CHECK:STDOUT: %.18: type = assoc_entity_type %As.type.5, %Convert.type.11 [template] -// CHECK:STDOUT: %.19: %.18 = assoc_entity element0, imports.%import_ref.35 [template] +// CHECK:STDOUT: %.19: %.18 = assoc_entity imports.%import_ref.35, element0 [template] // CHECK:STDOUT: %Convert.type.12: type = fn_type @Convert.10, @impl.8(%N) [symbolic] // CHECK:STDOUT: %Convert.12: %Convert.type.12 = struct_value () [symbolic] // CHECK:STDOUT: %.20: = interface_witness (%Convert.12) [symbolic] @@ -1865,8 +1865,8 @@ var c_bad: C({.a = 3, .b = 4}) = F(); // CHECK:STDOUT: %Convert.type.13: type = fn_type @Convert.1, @ImplicitAs(%i32) [template] // CHECK:STDOUT: %Convert.13: %Convert.type.13 = struct_value () [template] // CHECK:STDOUT: %.29: type = assoc_entity_type %ImplicitAs.type.6, %Convert.type.13 [template] -// CHECK:STDOUT: %.30: %.29 = assoc_entity element0, imports.%import_ref.11 [template] -// CHECK:STDOUT: %.31: %.2 = assoc_entity element0, imports.%import_ref.41 [symbolic] +// CHECK:STDOUT: %.30: %.29 = assoc_entity imports.%import_ref.11, element0 [template] +// CHECK:STDOUT: %.31: %.2 = assoc_entity imports.%import_ref.41, element0 [symbolic] // CHECK:STDOUT: %Convert.type.14: type = fn_type @Convert.2, @impl.1(%.23) [template] // CHECK:STDOUT: %Convert.14: %Convert.type.14 = struct_value () [template] // CHECK:STDOUT: %.32: = interface_witness (%Convert.14) [template] @@ -1888,7 +1888,7 @@ var c_bad: C({.a = 3, .b = 4}) = F(); // CHECK:STDOUT: %Convert.type.15: type = fn_type @Convert.1, @ImplicitAs(%C.3) [template] // CHECK:STDOUT: %Convert.15: %Convert.type.15 = struct_value () [template] // CHECK:STDOUT: %.42: type = assoc_entity_type %ImplicitAs.type.7, %Convert.type.15 [template] -// CHECK:STDOUT: %.43: %.42 = assoc_entity element0, imports.%import_ref.11 [template] +// CHECK:STDOUT: %.43: %.42 = assoc_entity imports.%import_ref.11, element0 [template] // CHECK:STDOUT: } // CHECK:STDOUT: // CHECK:STDOUT: imports { @@ -1981,7 +1981,7 @@ var c_bad: C({.a = 3, .b = 4}) = F(); // CHECK:STDOUT: %Convert.type: type = fn_type @Convert.1, @ImplicitAs(%Dest) [symbolic = %Convert.type (constants.%Convert.type.1)] // CHECK:STDOUT: %Convert: @ImplicitAs.%Convert.type (%Convert.type.1) = struct_value () [symbolic = %Convert (constants.%Convert.1)] // CHECK:STDOUT: %.1: type = assoc_entity_type @ImplicitAs.%ImplicitAs.type (%ImplicitAs.type.2), @ImplicitAs.%Convert.type (%Convert.type.1) [symbolic = %.1 (constants.%.2)] -// CHECK:STDOUT: %.2: @ImplicitAs.%.1 (%.2) = assoc_entity element0, imports.%import_ref.11 [symbolic = %.2 (constants.%.3)] +// CHECK:STDOUT: %.2: @ImplicitAs.%.1 (%.2) = assoc_entity imports.%import_ref.11, element0 [symbolic = %.2 (constants.%.3)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: !members: @@ -2001,7 +2001,7 @@ var c_bad: C({.a = 3, .b = 4}) = F(); // CHECK:STDOUT: %Convert.type: type = fn_type @Convert.6, @As(%Dest) [symbolic = %Convert.type (constants.%Convert.type.7)] // CHECK:STDOUT: %Convert: @As.%Convert.type (%Convert.type.7) = struct_value () [symbolic = %Convert (constants.%Convert.7)] // CHECK:STDOUT: %.1: type = assoc_entity_type @As.%As.type (%As.type.2), @As.%Convert.type (%Convert.type.7) [symbolic = %.1 (constants.%.12)] -// CHECK:STDOUT: %.2: @As.%.1 (%.12) = assoc_entity element0, imports.%import_ref.28 [symbolic = %.2 (constants.%.13)] +// CHECK:STDOUT: %.2: @As.%.1 (%.12) = assoc_entity imports.%import_ref.28, element0 [symbolic = %.2 (constants.%.13)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: !members: diff --git a/toolchain/check/testdata/tuple/import.carbon b/toolchain/check/testdata/tuple/import.carbon index 3049aca20abc8..070e1bbb20625 100644 --- a/toolchain/check/testdata/tuple/import.carbon +++ b/toolchain/check/testdata/tuple/import.carbon @@ -310,7 +310,7 @@ var c_bad: C((3, 4)) = F(); // CHECK:STDOUT: %Convert.1: %Convert.type.1 = struct_value () [symbolic] // CHECK:STDOUT: %.1: type = facet_access_type %Self.2 [symbolic] // CHECK:STDOUT: %.2: type = assoc_entity_type %ImplicitAs.type.2, %Convert.type.1 [symbolic] -// CHECK:STDOUT: %.3: %.2 = assoc_entity element0, imports.%import_ref.11 [symbolic] +// CHECK:STDOUT: %.3: %.2 = assoc_entity imports.%import_ref.11, element0 [symbolic] // CHECK:STDOUT: %Convert.type.2: type = fn_type @Convert.2, @impl.1(%N) [symbolic] // CHECK:STDOUT: %Convert.2: %Convert.type.2 = struct_value () [symbolic] // CHECK:STDOUT: %.4: = interface_witness (%Convert.2) [symbolic] @@ -327,7 +327,7 @@ var c_bad: C((3, 4)) = F(); // CHECK:STDOUT: %Convert.type.5: type = fn_type @Convert.1, @ImplicitAs(Core.IntLiteral) [template] // CHECK:STDOUT: %Convert.5: %Convert.type.5 = struct_value () [template] // CHECK:STDOUT: %.8: type = assoc_entity_type %ImplicitAs.type.5, %Convert.type.5 [template] -// CHECK:STDOUT: %.9: %.8 = assoc_entity element0, imports.%import_ref.18 [template] +// CHECK:STDOUT: %.9: %.8 = assoc_entity imports.%import_ref.18, element0 [template] // CHECK:STDOUT: %Convert.type.6: type = fn_type @Convert.5, @impl.4(%N) [symbolic] // CHECK:STDOUT: %Convert.6: %Convert.type.6 = struct_value () [symbolic] // CHECK:STDOUT: %.10: = interface_witness (%Convert.6) [symbolic] @@ -339,7 +339,7 @@ var c_bad: C((3, 4)) = F(); // CHECK:STDOUT: %Convert.7: %Convert.type.7 = struct_value () [symbolic] // CHECK:STDOUT: %.11: type = facet_access_type %Self.4 [symbolic] // CHECK:STDOUT: %.12: type = assoc_entity_type %As.type.2, %Convert.type.7 [symbolic] -// CHECK:STDOUT: %.13: %.12 = assoc_entity element0, imports.%import_ref.28 [symbolic] +// CHECK:STDOUT: %.13: %.12 = assoc_entity imports.%import_ref.28, element0 [symbolic] // CHECK:STDOUT: %Convert.type.8: type = fn_type @Convert.7, @impl.5(%N) [symbolic] // CHECK:STDOUT: %Convert.8: %Convert.type.8 = struct_value () [symbolic] // CHECK:STDOUT: %.14: = interface_witness (%Convert.8) [symbolic] @@ -355,7 +355,7 @@ var c_bad: C((3, 4)) = F(); // CHECK:STDOUT: %Convert.type.11: type = fn_type @Convert.6, @As(Core.IntLiteral) [template] // CHECK:STDOUT: %Convert.11: %Convert.type.11 = struct_value () [template] // CHECK:STDOUT: %.18: type = assoc_entity_type %As.type.5, %Convert.type.11 [template] -// CHECK:STDOUT: %.19: %.18 = assoc_entity element0, imports.%import_ref.35 [template] +// CHECK:STDOUT: %.19: %.18 = assoc_entity imports.%import_ref.35, element0 [template] // CHECK:STDOUT: %Convert.type.12: type = fn_type @Convert.10, @impl.8(%N) [symbolic] // CHECK:STDOUT: %Convert.12: %Convert.type.12 = struct_value () [symbolic] // CHECK:STDOUT: %.20: = interface_witness (%Convert.12) [symbolic] @@ -382,8 +382,8 @@ var c_bad: C((3, 4)) = F(); // CHECK:STDOUT: %Convert.type.13: type = fn_type @Convert.1, @ImplicitAs(%i32) [template] // CHECK:STDOUT: %Convert.13: %Convert.type.13 = struct_value () [template] // CHECK:STDOUT: %.29: type = assoc_entity_type %ImplicitAs.type.6, %Convert.type.13 [template] -// CHECK:STDOUT: %.30: %.29 = assoc_entity element0, imports.%import_ref.11 [template] -// CHECK:STDOUT: %.31: %.2 = assoc_entity element0, imports.%import_ref.42 [symbolic] +// CHECK:STDOUT: %.30: %.29 = assoc_entity imports.%import_ref.11, element0 [template] +// CHECK:STDOUT: %.31: %.2 = assoc_entity imports.%import_ref.42, element0 [symbolic] // CHECK:STDOUT: %Convert.type.14: type = fn_type @Convert.2, @impl.1(%.21) [template] // CHECK:STDOUT: %Convert.14: %Convert.type.14 = struct_value () [template] // CHECK:STDOUT: %.32: = interface_witness (%Convert.14) [template] @@ -526,7 +526,7 @@ var c_bad: C((3, 4)) = F(); // CHECK:STDOUT: %Convert.type: type = fn_type @Convert.1, @ImplicitAs(%Dest) [symbolic = %Convert.type (constants.%Convert.type.1)] // CHECK:STDOUT: %Convert: @ImplicitAs.%Convert.type (%Convert.type.1) = struct_value () [symbolic = %Convert (constants.%Convert.1)] // CHECK:STDOUT: %.1: type = assoc_entity_type @ImplicitAs.%ImplicitAs.type (%ImplicitAs.type.2), @ImplicitAs.%Convert.type (%Convert.type.1) [symbolic = %.1 (constants.%.2)] -// CHECK:STDOUT: %.2: @ImplicitAs.%.1 (%.2) = assoc_entity element0, imports.%import_ref.11 [symbolic = %.2 (constants.%.3)] +// CHECK:STDOUT: %.2: @ImplicitAs.%.1 (%.2) = assoc_entity imports.%import_ref.11, element0 [symbolic = %.2 (constants.%.3)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: !members: @@ -546,7 +546,7 @@ var c_bad: C((3, 4)) = F(); // CHECK:STDOUT: %Convert.type: type = fn_type @Convert.6, @As(%Dest) [symbolic = %Convert.type (constants.%Convert.type.7)] // CHECK:STDOUT: %Convert: @As.%Convert.type (%Convert.type.7) = struct_value () [symbolic = %Convert (constants.%Convert.7)] // CHECK:STDOUT: %.1: type = assoc_entity_type @As.%As.type (%As.type.2), @As.%Convert.type (%Convert.type.7) [symbolic = %.1 (constants.%.12)] -// CHECK:STDOUT: %.2: @As.%.1 (%.12) = assoc_entity element0, imports.%import_ref.28 [symbolic = %.2 (constants.%.13)] +// CHECK:STDOUT: %.2: @As.%.1 (%.12) = assoc_entity imports.%import_ref.28, element0 [symbolic = %.2 (constants.%.13)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: !members: @@ -1152,7 +1152,7 @@ var c_bad: C((3, 4)) = F(); // CHECK:STDOUT: %Convert.1: %Convert.type.1 = struct_value () [symbolic] // CHECK:STDOUT: %.1: type = facet_access_type %Self.2 [symbolic] // CHECK:STDOUT: %.2: type = assoc_entity_type %ImplicitAs.type.2, %Convert.type.1 [symbolic] -// CHECK:STDOUT: %.3: %.2 = assoc_entity element0, imports.%import_ref.11 [symbolic] +// CHECK:STDOUT: %.3: %.2 = assoc_entity imports.%import_ref.11, element0 [symbolic] // CHECK:STDOUT: %Convert.type.2: type = fn_type @Convert.2, @impl.1(%N) [symbolic] // CHECK:STDOUT: %Convert.2: %Convert.type.2 = struct_value () [symbolic] // CHECK:STDOUT: %.4: = interface_witness (%Convert.2) [symbolic] @@ -1169,7 +1169,7 @@ var c_bad: C((3, 4)) = F(); // CHECK:STDOUT: %Convert.type.5: type = fn_type @Convert.1, @ImplicitAs(Core.IntLiteral) [template] // CHECK:STDOUT: %Convert.5: %Convert.type.5 = struct_value () [template] // CHECK:STDOUT: %.8: type = assoc_entity_type %ImplicitAs.type.5, %Convert.type.5 [template] -// CHECK:STDOUT: %.9: %.8 = assoc_entity element0, imports.%import_ref.18 [template] +// CHECK:STDOUT: %.9: %.8 = assoc_entity imports.%import_ref.18, element0 [template] // CHECK:STDOUT: %Convert.type.6: type = fn_type @Convert.5, @impl.4(%N) [symbolic] // CHECK:STDOUT: %Convert.6: %Convert.type.6 = struct_value () [symbolic] // CHECK:STDOUT: %.10: = interface_witness (%Convert.6) [symbolic] @@ -1181,7 +1181,7 @@ var c_bad: C((3, 4)) = F(); // CHECK:STDOUT: %Convert.7: %Convert.type.7 = struct_value () [symbolic] // CHECK:STDOUT: %.11: type = facet_access_type %Self.4 [symbolic] // CHECK:STDOUT: %.12: type = assoc_entity_type %As.type.2, %Convert.type.7 [symbolic] -// CHECK:STDOUT: %.13: %.12 = assoc_entity element0, imports.%import_ref.28 [symbolic] +// CHECK:STDOUT: %.13: %.12 = assoc_entity imports.%import_ref.28, element0 [symbolic] // CHECK:STDOUT: %Convert.type.8: type = fn_type @Convert.7, @impl.5(%N) [symbolic] // CHECK:STDOUT: %Convert.8: %Convert.type.8 = struct_value () [symbolic] // CHECK:STDOUT: %.14: = interface_witness (%Convert.8) [symbolic] @@ -1197,7 +1197,7 @@ var c_bad: C((3, 4)) = F(); // CHECK:STDOUT: %Convert.type.11: type = fn_type @Convert.6, @As(Core.IntLiteral) [template] // CHECK:STDOUT: %Convert.11: %Convert.type.11 = struct_value () [template] // CHECK:STDOUT: %.18: type = assoc_entity_type %As.type.5, %Convert.type.11 [template] -// CHECK:STDOUT: %.19: %.18 = assoc_entity element0, imports.%import_ref.35 [template] +// CHECK:STDOUT: %.19: %.18 = assoc_entity imports.%import_ref.35, element0 [template] // CHECK:STDOUT: %Convert.type.12: type = fn_type @Convert.10, @impl.8(%N) [symbolic] // CHECK:STDOUT: %Convert.12: %Convert.type.12 = struct_value () [symbolic] // CHECK:STDOUT: %.20: = interface_witness (%Convert.12) [symbolic] @@ -1295,7 +1295,7 @@ var c_bad: C((3, 4)) = F(); // CHECK:STDOUT: %Convert.type: type = fn_type @Convert.1, @ImplicitAs(%Dest) [symbolic = %Convert.type (constants.%Convert.type.1)] // CHECK:STDOUT: %Convert: @ImplicitAs.%Convert.type (%Convert.type.1) = struct_value () [symbolic = %Convert (constants.%Convert.1)] // CHECK:STDOUT: %.1: type = assoc_entity_type @ImplicitAs.%ImplicitAs.type (%ImplicitAs.type.2), @ImplicitAs.%Convert.type (%Convert.type.1) [symbolic = %.1 (constants.%.2)] -// CHECK:STDOUT: %.2: @ImplicitAs.%.1 (%.2) = assoc_entity element0, imports.%import_ref.11 [symbolic = %.2 (constants.%.3)] +// CHECK:STDOUT: %.2: @ImplicitAs.%.1 (%.2) = assoc_entity imports.%import_ref.11, element0 [symbolic = %.2 (constants.%.3)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: !members: @@ -1315,7 +1315,7 @@ var c_bad: C((3, 4)) = F(); // CHECK:STDOUT: %Convert.type: type = fn_type @Convert.6, @As(%Dest) [symbolic = %Convert.type (constants.%Convert.type.7)] // CHECK:STDOUT: %Convert: @As.%Convert.type (%Convert.type.7) = struct_value () [symbolic = %Convert (constants.%Convert.7)] // CHECK:STDOUT: %.1: type = assoc_entity_type @As.%As.type (%As.type.2), @As.%Convert.type (%Convert.type.7) [symbolic = %.1 (constants.%.12)] -// CHECK:STDOUT: %.2: @As.%.1 (%.12) = assoc_entity element0, imports.%import_ref.28 [symbolic = %.2 (constants.%.13)] +// CHECK:STDOUT: %.2: @As.%.1 (%.12) = assoc_entity imports.%import_ref.28, element0 [symbolic = %.2 (constants.%.13)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: !members: @@ -1852,7 +1852,7 @@ var c_bad: C((3, 4)) = F(); // CHECK:STDOUT: %Convert.1: %Convert.type.1 = struct_value () [symbolic] // CHECK:STDOUT: %.1: type = facet_access_type %Self.2 [symbolic] // CHECK:STDOUT: %.2: type = assoc_entity_type %ImplicitAs.type.2, %Convert.type.1 [symbolic] -// CHECK:STDOUT: %.3: %.2 = assoc_entity element0, imports.%import_ref.11 [symbolic] +// CHECK:STDOUT: %.3: %.2 = assoc_entity imports.%import_ref.11, element0 [symbolic] // CHECK:STDOUT: %Convert.type.2: type = fn_type @Convert.2, @impl.1(%N) [symbolic] // CHECK:STDOUT: %Convert.2: %Convert.type.2 = struct_value () [symbolic] // CHECK:STDOUT: %.4: = interface_witness (%Convert.2) [symbolic] @@ -1869,7 +1869,7 @@ var c_bad: C((3, 4)) = F(); // CHECK:STDOUT: %Convert.type.5: type = fn_type @Convert.1, @ImplicitAs(Core.IntLiteral) [template] // CHECK:STDOUT: %Convert.5: %Convert.type.5 = struct_value () [template] // CHECK:STDOUT: %.8: type = assoc_entity_type %ImplicitAs.type.5, %Convert.type.5 [template] -// CHECK:STDOUT: %.9: %.8 = assoc_entity element0, imports.%import_ref.18 [template] +// CHECK:STDOUT: %.9: %.8 = assoc_entity imports.%import_ref.18, element0 [template] // CHECK:STDOUT: %Convert.type.6: type = fn_type @Convert.5, @impl.4(%N) [symbolic] // CHECK:STDOUT: %Convert.6: %Convert.type.6 = struct_value () [symbolic] // CHECK:STDOUT: %.10: = interface_witness (%Convert.6) [symbolic] @@ -1881,7 +1881,7 @@ var c_bad: C((3, 4)) = F(); // CHECK:STDOUT: %Convert.7: %Convert.type.7 = struct_value () [symbolic] // CHECK:STDOUT: %.11: type = facet_access_type %Self.4 [symbolic] // CHECK:STDOUT: %.12: type = assoc_entity_type %As.type.2, %Convert.type.7 [symbolic] -// CHECK:STDOUT: %.13: %.12 = assoc_entity element0, imports.%import_ref.28 [symbolic] +// CHECK:STDOUT: %.13: %.12 = assoc_entity imports.%import_ref.28, element0 [symbolic] // CHECK:STDOUT: %Convert.type.8: type = fn_type @Convert.7, @impl.5(%N) [symbolic] // CHECK:STDOUT: %Convert.8: %Convert.type.8 = struct_value () [symbolic] // CHECK:STDOUT: %.14: = interface_witness (%Convert.8) [symbolic] @@ -1897,7 +1897,7 @@ var c_bad: C((3, 4)) = F(); // CHECK:STDOUT: %Convert.type.11: type = fn_type @Convert.6, @As(Core.IntLiteral) [template] // CHECK:STDOUT: %Convert.11: %Convert.type.11 = struct_value () [template] // CHECK:STDOUT: %.18: type = assoc_entity_type %As.type.5, %Convert.type.11 [template] -// CHECK:STDOUT: %.19: %.18 = assoc_entity element0, imports.%import_ref.35 [template] +// CHECK:STDOUT: %.19: %.18 = assoc_entity imports.%import_ref.35, element0 [template] // CHECK:STDOUT: %Convert.type.12: type = fn_type @Convert.10, @impl.8(%N) [symbolic] // CHECK:STDOUT: %Convert.12: %Convert.type.12 = struct_value () [symbolic] // CHECK:STDOUT: %.20: = interface_witness (%Convert.12) [symbolic] @@ -1915,8 +1915,8 @@ var c_bad: C((3, 4)) = F(); // CHECK:STDOUT: %Convert.type.13: type = fn_type @Convert.1, @ImplicitAs(%i32) [template] // CHECK:STDOUT: %Convert.13: %Convert.type.13 = struct_value () [template] // CHECK:STDOUT: %.27: type = assoc_entity_type %ImplicitAs.type.6, %Convert.type.13 [template] -// CHECK:STDOUT: %.28: %.27 = assoc_entity element0, imports.%import_ref.11 [template] -// CHECK:STDOUT: %.29: %.2 = assoc_entity element0, imports.%import_ref.41 [symbolic] +// CHECK:STDOUT: %.28: %.27 = assoc_entity imports.%import_ref.11, element0 [template] +// CHECK:STDOUT: %.29: %.2 = assoc_entity imports.%import_ref.41, element0 [symbolic] // CHECK:STDOUT: %Convert.type.14: type = fn_type @Convert.2, @impl.1(%.23) [template] // CHECK:STDOUT: %Convert.14: %Convert.type.14 = struct_value () [template] // CHECK:STDOUT: %.30: = interface_witness (%Convert.14) [template] @@ -1938,7 +1938,7 @@ var c_bad: C((3, 4)) = F(); // CHECK:STDOUT: %Convert.type.15: type = fn_type @Convert.1, @ImplicitAs(%C.3) [template] // CHECK:STDOUT: %Convert.15: %Convert.type.15 = struct_value () [template] // CHECK:STDOUT: %.40: type = assoc_entity_type %ImplicitAs.type.7, %Convert.type.15 [template] -// CHECK:STDOUT: %.41: %.40 = assoc_entity element0, imports.%import_ref.11 [template] +// CHECK:STDOUT: %.41: %.40 = assoc_entity imports.%import_ref.11, element0 [template] // CHECK:STDOUT: } // CHECK:STDOUT: // CHECK:STDOUT: imports { @@ -2031,7 +2031,7 @@ var c_bad: C((3, 4)) = F(); // CHECK:STDOUT: %Convert.type: type = fn_type @Convert.1, @ImplicitAs(%Dest) [symbolic = %Convert.type (constants.%Convert.type.1)] // CHECK:STDOUT: %Convert: @ImplicitAs.%Convert.type (%Convert.type.1) = struct_value () [symbolic = %Convert (constants.%Convert.1)] // CHECK:STDOUT: %.1: type = assoc_entity_type @ImplicitAs.%ImplicitAs.type (%ImplicitAs.type.2), @ImplicitAs.%Convert.type (%Convert.type.1) [symbolic = %.1 (constants.%.2)] -// CHECK:STDOUT: %.2: @ImplicitAs.%.1 (%.2) = assoc_entity element0, imports.%import_ref.11 [symbolic = %.2 (constants.%.3)] +// CHECK:STDOUT: %.2: @ImplicitAs.%.1 (%.2) = assoc_entity imports.%import_ref.11, element0 [symbolic = %.2 (constants.%.3)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: !members: @@ -2051,7 +2051,7 @@ var c_bad: C((3, 4)) = F(); // CHECK:STDOUT: %Convert.type: type = fn_type @Convert.6, @As(%Dest) [symbolic = %Convert.type (constants.%Convert.type.7)] // CHECK:STDOUT: %Convert: @As.%Convert.type (%Convert.type.7) = struct_value () [symbolic = %Convert (constants.%Convert.7)] // CHECK:STDOUT: %.1: type = assoc_entity_type @As.%As.type (%As.type.2), @As.%Convert.type (%Convert.type.7) [symbolic = %.1 (constants.%.12)] -// CHECK:STDOUT: %.2: @As.%.1 (%.12) = assoc_entity element0, imports.%import_ref.28 [symbolic = %.2 (constants.%.13)] +// CHECK:STDOUT: %.2: @As.%.1 (%.12) = assoc_entity imports.%import_ref.28, element0 [symbolic = %.2 (constants.%.13)] // CHECK:STDOUT: // CHECK:STDOUT: interface { // CHECK:STDOUT: !members: diff --git a/toolchain/check/testdata/where_expr/constraints.carbon b/toolchain/check/testdata/where_expr/constraints.carbon index 7c120c1bb48a4..93e3a763387f3 100644 --- a/toolchain/check/testdata/where_expr/constraints.carbon +++ b/toolchain/check/testdata/where_expr/constraints.carbon @@ -167,10 +167,10 @@ let B: type where .Self impls A = D; // CHECK:STDOUT: %I.type.1: type = facet_type <@I> [template] // CHECK:STDOUT: %Self.2: %I.type.1 = bind_symbolic_name Self, 0 [symbolic] // CHECK:STDOUT: %.1: type = assoc_entity_type %I.type.1, type [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @I.%Member [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @I.%Member, element0 [template] // CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [template] // CHECK:STDOUT: %.3: type = assoc_entity_type %I.type.1, %J.type.1 [template] -// CHECK:STDOUT: %.4: %.3 = assoc_entity element1, @I.%Second [template] +// CHECK:STDOUT: %.4: %.3 = assoc_entity @I.%Second, element1 [template] // CHECK:STDOUT: %.Self.1: %I.type.1 = bind_symbolic_name .Self, 0 [symbolic] // CHECK:STDOUT: %I.type.2: type = facet_type <@I where TODO> [template] // CHECK:STDOUT: %U: %I.type.2 = bind_symbolic_name U, 0 [symbolic] @@ -278,10 +278,10 @@ let B: type where .Self impls A = D; // CHECK:STDOUT: interface @I { // CHECK:STDOUT: %Self: %I.type.1 = bind_symbolic_name Self, 0 [symbolic = constants.%Self.2] // CHECK:STDOUT: %Member: type = assoc_const_decl Member [template] -// CHECK:STDOUT: %.loc7: %.1 = assoc_entity element0, %Member [template = constants.%.2] +// CHECK:STDOUT: %.loc7: %.1 = assoc_entity %Member, element0 [template = constants.%.2] // CHECK:STDOUT: %J.ref: type = name_ref J, file.%J.decl [template = constants.%J.type.1] // CHECK:STDOUT: %Second: %J.type.1 = assoc_const_decl Second [template] -// CHECK:STDOUT: %.loc8: %.3 = assoc_entity element1, %Second [template = constants.%.4] +// CHECK:STDOUT: %.loc8: %.3 = assoc_entity %Second, element1 [template = constants.%.4] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self @@ -332,7 +332,7 @@ let B: type where .Self impls A = D; // CHECK:STDOUT: %N.type.1: type = facet_type <@N> [template] // CHECK:STDOUT: %Self: %N.type.1 = bind_symbolic_name Self, 0 [symbolic] // CHECK:STDOUT: %.1: type = assoc_entity_type %N.type.1, type [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @N.%P [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @N.%P, element0 [template] // CHECK:STDOUT: %.Self: %N.type.1 = bind_symbolic_name .Self, 0 [symbolic] // CHECK:STDOUT: %.3: = facet_access_witness %.Self [symbolic] // CHECK:STDOUT: %.4: type = interface_witness_access %.3, element0 [symbolic] @@ -382,7 +382,7 @@ let B: type where .Self impls A = D; // CHECK:STDOUT: interface @N { // CHECK:STDOUT: %Self: %N.type.1 = bind_symbolic_name Self, 0 [symbolic = constants.%Self] // CHECK:STDOUT: %P: type = assoc_const_decl P [template] -// CHECK:STDOUT: %.loc5: %.1 = assoc_entity element0, %P [template = constants.%.2] +// CHECK:STDOUT: %.loc5: %.1 = assoc_entity %P, element0 [template = constants.%.2] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self @@ -412,7 +412,7 @@ let B: type where .Self impls A = D; // CHECK:STDOUT: %K.type.1: type = facet_type <@K> [template] // CHECK:STDOUT: %Self.3: %K.type.1 = bind_symbolic_name Self, 0 [symbolic] // CHECK:STDOUT: %.1: type = assoc_entity_type %K.type.1, %L.type [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @K.%Associated [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @K.%Associated, element0 [template] // CHECK:STDOUT: %.Self: %K.type.1 = bind_symbolic_name .Self, 0 [symbolic] // CHECK:STDOUT: %.3: = facet_access_witness %.Self [symbolic] // CHECK:STDOUT: %.4: %L.type = interface_witness_access %.3, element0 [symbolic] @@ -484,7 +484,7 @@ let B: type where .Self impls A = D; // CHECK:STDOUT: %Self: %K.type.1 = bind_symbolic_name Self, 0 [symbolic = constants.%Self.3] // CHECK:STDOUT: %L.ref: type = name_ref L, file.%L.decl [template = constants.%L.type] // CHECK:STDOUT: %Associated: %L.type = assoc_const_decl Associated [template] -// CHECK:STDOUT: %.loc8: %.1 = assoc_entity element0, %Associated [template = constants.%.2] +// CHECK:STDOUT: %.loc8: %.1 = assoc_entity %Associated, element0 [template = constants.%.2] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self @@ -510,7 +510,7 @@ let B: type where .Self impls A = D; // CHECK:STDOUT: %I.type.1: type = facet_type <@I> [template] // CHECK:STDOUT: %.Self: %I.type.1 = bind_symbolic_name .Self, 0 [symbolic] // CHECK:STDOUT: %.1: type = assoc_entity_type %I.type.1, type [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, imports.%import_ref.11 [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity imports.%import_ref.11, element0 [template] // CHECK:STDOUT: %.3: = facet_access_witness %.Self [symbolic] // CHECK:STDOUT: %.4: type = interface_witness_access %.3, element0 [symbolic] // CHECK:STDOUT: %.5: Core.IntLiteral = int_value 2 [template] diff --git a/toolchain/check/testdata/where_expr/designator.carbon b/toolchain/check/testdata/where_expr/designator.carbon index b4dd57fb4c79f..db8da8fd86188 100644 --- a/toolchain/check/testdata/where_expr/designator.carbon +++ b/toolchain/check/testdata/where_expr/designator.carbon @@ -92,7 +92,7 @@ class D { // CHECK:STDOUT: %I.type.1: type = facet_type <@I> [template] // CHECK:STDOUT: %Self: %I.type.1 = bind_symbolic_name Self, 0 [symbolic] // CHECK:STDOUT: %.1: type = assoc_entity_type %I.type.1, type [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @I.%Member [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @I.%Member, element0 [template] // CHECK:STDOUT: %.Self.1: %I.type.1 = bind_symbolic_name .Self, 0 [symbolic] // CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [template] // CHECK:STDOUT: %I.type.2: type = facet_type <@I where TODO> [template] @@ -181,7 +181,7 @@ class D { // CHECK:STDOUT: interface @I { // CHECK:STDOUT: %Self: %I.type.1 = bind_symbolic_name Self, 0 [symbolic = constants.%Self] // CHECK:STDOUT: %Member: type = assoc_const_decl Member [template] -// CHECK:STDOUT: %.loc5: %.1 = assoc_entity element0, %Member [template = constants.%.2] +// CHECK:STDOUT: %.loc5: %.1 = assoc_entity %Member, element0 [template = constants.%.2] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self @@ -231,7 +231,7 @@ class D { // CHECK:STDOUT: %J.type.1: type = facet_type <@J> [template] // CHECK:STDOUT: %Self: %J.type.1 = bind_symbolic_name Self, 0 [symbolic] // CHECK:STDOUT: %.1: type = assoc_entity_type %J.type.1, type [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @J.%Member [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @J.%Member, element0 [template] // CHECK:STDOUT: %.Self: %J.type.1 = bind_symbolic_name .Self, 0 [symbolic] // CHECK:STDOUT: %.3: type = struct_type {} [template] // CHECK:STDOUT: %J.type.2: type = facet_type <@J where TODO> [template] @@ -276,7 +276,7 @@ class D { // CHECK:STDOUT: interface @J { // CHECK:STDOUT: %Self: %J.type.1 = bind_symbolic_name Self, 0 [symbolic = constants.%Self] // CHECK:STDOUT: %Member: type = assoc_const_decl Member [template] -// CHECK:STDOUT: %.loc5: %.1 = assoc_entity element0, %Member [template = constants.%.2] +// CHECK:STDOUT: %.loc5: %.1 = assoc_entity %Member, element0 [template = constants.%.2] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self diff --git a/toolchain/check/testdata/where_expr/non_generic.carbon b/toolchain/check/testdata/where_expr/non_generic.carbon index 421885f053077..ad09115896450 100644 --- a/toolchain/check/testdata/where_expr/non_generic.carbon +++ b/toolchain/check/testdata/where_expr/non_generic.carbon @@ -19,7 +19,7 @@ fn NotGenericF(U: I where .T == i32) {} // CHECK:STDOUT: %I.type.1: type = facet_type <@I> [template] // CHECK:STDOUT: %Self: %I.type.1 = bind_symbolic_name Self, 0 [symbolic] // CHECK:STDOUT: %.1: type = assoc_entity_type %I.type.1, type [template] -// CHECK:STDOUT: %.2: %.1 = assoc_entity element0, @I.%T [template] +// CHECK:STDOUT: %.2: %.1 = assoc_entity @I.%T, element0 [template] // CHECK:STDOUT: %.Self: %I.type.1 = bind_symbolic_name .Self, 0 [symbolic] // CHECK:STDOUT: %.3: = facet_access_witness %.Self [symbolic] // CHECK:STDOUT: %.4: type = interface_witness_access %.3, element0 [symbolic] @@ -71,7 +71,7 @@ fn NotGenericF(U: I where .T == i32) {} // CHECK:STDOUT: interface @I { // CHECK:STDOUT: %Self: %I.type.1 = bind_symbolic_name Self, 0 [symbolic = constants.%Self] // CHECK:STDOUT: %T: type = assoc_const_decl T [template] -// CHECK:STDOUT: %.loc11: %.1 = assoc_entity element0, %T [template = constants.%.2] +// CHECK:STDOUT: %.loc11: %.1 = assoc_entity %T, element0 [template = constants.%.2] // CHECK:STDOUT: // CHECK:STDOUT: !members: // CHECK:STDOUT: .Self = %Self diff --git a/toolchain/docs/check.md b/toolchain/docs/check.md index 826a886aa173c..db80ff9fc480e 100644 --- a/toolchain/docs/check.md +++ b/toolchain/docs/check.md @@ -84,10 +84,6 @@ instruction, as described in [sem_ir/typed_insts.h](/toolchain/sem_ir/typed_insts.h) (also see [adding features for Check](adding_features.md#check)): -- A `Parse::Node parse_node;` member that tracks its location is present on - almost all instructions, except instructions like `SemIR::Builtin` that - don't have an associated location. - - A `SemIR::TypeId type_id;` member that describes the type of the instruction is present on all instructions that produce a value. This includes namespace instructions, which are modeled as producing a value of "namespace" type, @@ -96,10 +92,20 @@ instruction, as described in - Up to two additional, kind-specific members. For example `SemIR::Assign` has members `InstId lhs_id` and `InstId rhs_id`. +- Optionally, an `ElementIndex index` field for instructions that refer to a + single element from a larger set. For example, `SemIR::ClassElementAccess` + has an `ElementIndex` into the fields of the class to define which field it + is accessing. + Instructions are stored as type-erased `SemIR::Inst` objects, which store the instruction kind and the (up to) four fields described above. This balances the size of `SemIR::Inst` against the overhead of indirection. +Most instructions have with them a `LocId` that tracks its location, and is +stored on the `InstStore` and retrieved by `GetLocId()`. The exception to this +is `SemIR::Builtin` which do come with an associated location (as they do not +come from source code) and for which `GetLocId()` will return `LocId::Invalid`. + A `SemIR::InstBlock` can represent a code block. However, it can also be created when a series of instructions needs to be closely associated, such as a parameter list. diff --git a/toolchain/sem_ir/typed_insts.h b/toolchain/sem_ir/typed_insts.h index 937c7d39e55eb..4916d62c5aca0 100644 --- a/toolchain/sem_ir/typed_insts.h +++ b/toolchain/sem_ir/typed_insts.h @@ -21,6 +21,8 @@ // value. This includes instructions that produce an abstract value, such as a // `Namespace`, for which a placeholder type should be used. // - Up to two `[...]Id` members describing the contents of the struct. +// - Optionally, a `ElementIndex index;` member, for instruction that represent +// one of a set of elements (e.g. a field from a class). // // The field names here matter -- the fields must have the names specified // above, when present. When converting to a `SemIR::Inst`, the `kind` and @@ -216,8 +218,8 @@ struct AssociatedEntity { // The type of the associated entity. This is an AssociatedEntityType. TypeId type_id; - ElementIndex index; AbsoluteInstId decl_id; + ElementIndex index; }; // The type of an expression that names an associated entity, such as