Files
carbon-lang/toolchain/check/testdata/interface/require.carbon
T
Chandler Carruth 0072b28129 Start every diagnostic with a single message attached to the code (#8102)
This is the final step in landing the _structural_ updates to diagnostic
rendering.

The key idea here is that we want the primary diagnostic to have a
message clearly explaining the problem and attached to the code that has
that problem. This should be the starting point for readers working to
address the issue, but is rendered attached to the code snippet in
question so errors are always "in context" of the code with the error.
Everything else in a diagnostic is an additional label attached to code
to explain or help the reader understand the problem in the primary
message.

Previously, `ContextScope` resulted in some confusion here, as
diagnostic consumers turned messages into labels and made the message in
the context scope the message. In essence, this isn't a scope with
context _for_ a diagnostic (with two exceptions that should probably
have been an `AnnotationScope`), but a context within `check` where we
have a preferred message for a diagnostic emitted by general purpose
code we call into. For example, "class was forward declared here" starts
as an error, and then consumers render it as a label to make the message
from the context scope the error. We also grew an `AnnotationScope` to
handle the contextual information we want to show for a diagnostic (what
I would have assumed `ContextScope` actually did).

Now we have a `Diagnoser`: code in `check` that can better explain the
problem than shared logic it is calling into passes a callback that
builds a caller-specific diagnostic. The callee then can attach relevant
labels and emit it. Diagnostics no longer store `contexts` and consumers
no longer need the logic to restructure things. We move all (but two) of
the old contexts to be normal messages emitted in this way, and we move
some diagnostics to become labels. Each of the new normal messages
corresponds to a new diagnostic kind as usual. Common code following
this pattern now _requires_ the `Diagnoser` to be passed (or emit
nothing), and this uncovered three places where an empty context was
used that made the rendered form miss key information. All three are
fixed with new diagnostics, one already covered by tests, and two with
TODOs to add test coverage.

We also completely remove the old `ContextScope` and
`CARBON_DIAGNOSTIC_CONTEXT` and rename `AnnotationScope` to
`ContextScope`. It is only used to attach information about when/where a
diagnostic occurred.

Labels also no longer have categories. What were `Primary` are now
`ExtraRange`s on the diagnostic rather than labels. Labels are now
always informational.

`DeclaredName` now narrows the range of a label when the range is a
declaration of a named entity to only be the range of that name. For
entities that don't have a declared name, the entire declaration remains
the range. The code building and emitting these diagnostics can skip
them if the declared location isn't distinct from the diagnostic
location.

Wording is largely unchanged here so we can just review the _structural_
change. #7991 iterates using this to improve locations and adds missing
labels. A subsequent PR will iterate on the wording to increasingly fit
within this structural model.

This is separated out as a way to review incrementally, and so that
subsequently we don't have to review wording improvements that only make
sense in a new structure that you cannot see yet. It seems easier to
look at the structure here even with awkward wording.

Assisted-by: Claude Code
2026-11-22 05:19:35 +00:00

1115 lines
57 KiB
Plaintext

// Part of the Carbon Language project, under the Apache License v2.0 with LLVM
// Exceptions. See /LICENSE for license information.
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
//
// INCLUDE-FILE: toolchain/testing/testdata/min_prelude/convert.carbon
//
// AUTOUPDATE
// TIP: To test this file alone, run:
// TIP: bazel test //toolchain/testing:file_test --test_arg=--file_tests=toolchain/check/testdata/interface/require.carbon
// TIP: To dump output, run:
// TIP: bazel run //toolchain/testing:file_test -- --dump_output --file_tests=toolchain/check/testdata/interface/require.carbon
// --- fail_todo_extend.carbon
library "[[@TEST_NAME]]";
interface Y {
fn YY();
}
//@dump-sem-ir-begin
interface Z {
extend require impls Y;
}
//@dump-sem-ir-end
fn F(generic T: Z, generic t: T) {
// TODO: We find the name `YY`, but then fail to do impl lookup for `Y` in
// `T: Z` since the identified facet type doesn't include `Y`. The
// identified facet type needs to include extends inside interfaces?
// CHECK:STDERR: ╭─┤ fail_todo_extend.carbon:[[@LINE+8]]:3
// CHECK:STDERR: -> │ T.YY();
// CHECK:STDERR: · ┳━━━
// CHECK:STDERR: · ┗━━┫ error: cannot access member of interface `Y` in type `T` that does not
// CHECK:STDERR: · ┃ implement that interface
// CHECK:STDERR: · ┃ [MissingImplInMemberAccess]
// CHECK:STDERR: ╰────
// CHECK:STDERR:
T.YY();
// CHECK:STDERR: ╭─┤ fail_todo_extend.carbon:[[@LINE+8]]:3
// CHECK:STDERR: -> │ T.(Y.YY)();
// CHECK:STDERR: · ┳━━━━━━━
// CHECK:STDERR: · ┗━━┫ error: cannot convert type `T` that implements `Z` into type implementing
// CHECK:STDERR: · ┃ `Y`
// CHECK:STDERR: · ┃ [ConversionFailureFacetToFacet]
// CHECK:STDERR: ╰────
// CHECK:STDERR:
T.(Y.YY)();
// CHECK:STDERR: ╭─┤ fail_todo_extend.carbon:[[@LINE+8]]:3
// CHECK:STDERR: -> │ t.YY();
// CHECK:STDERR: · ┳━━━
// CHECK:STDERR: · ┗━━┫ error: cannot access member of interface `Y` in type `T` that does not
// CHECK:STDERR: · ┃ implement that interface
// CHECK:STDERR: · ┃ [MissingImplInMemberAccess]
// CHECK:STDERR: ╰────
// CHECK:STDERR:
t.YY();
}
// --- fail_todo_extend_with_self.carbon
library "[[@TEST_NAME]]";
interface Y(T: type) {
fn YY();
}
//@dump-sem-ir-begin
interface Z {
extend require impls Y(Self);
}
//@dump-sem-ir-end
fn F(generic T: Z) {
// TODO: We find the name `YY`, but then fail to do impl lookup for `Y` in
// `T: Z` since the identified facet type doesn't include `Y`. The
// identified facet type needs to include extends inside interfaces?
//
// CHECK:STDERR: ╭─┤ fail_todo_extend_with_self.carbon:[[@LINE+8]]:3
// CHECK:STDERR: -> │ T.YY();
// CHECK:STDERR: · ┳━━━
// CHECK:STDERR: · ┗━━┫ error: cannot access member of interface `Y(T)` in type `T` that does not
// CHECK:STDERR: · ┃ implement that interface
// CHECK:STDERR: · ┃ [MissingImplInMemberAccess]
// CHECK:STDERR: ╰────
// CHECK:STDERR:
T.YY();
// CHECK:STDERR: ╭─┤ fail_todo_extend_with_self.carbon:[[@LINE+8]]:3
// CHECK:STDERR: -> │ T.(Y(T).YY)();
// CHECK:STDERR: · ┳━━━━━━━━━━
// CHECK:STDERR: · ┗━━┫ error: cannot convert type `T` that implements `Z` into type implementing
// CHECK:STDERR: · ┃ `Y(T)`
// CHECK:STDERR: · ┃ [ConversionFailureFacetToFacet]
// CHECK:STDERR: ╰────
// CHECK:STDERR:
T.(Y(T).YY)();
}
// --- fail_todo_implicit_self_impls.carbon
library "[[@TEST_NAME]]";
interface Y {
fn YY();
}
//@dump-sem-ir-begin
interface Z {
require impls Y;
}
//@dump-sem-ir-end
fn F(generic T: Z) {
// CHECK:STDERR: ╭─┤ fail_todo_implicit_self_impls.carbon:[[@LINE+8]]:3
// CHECK:STDERR: -> │ T.(Y.YY)();
// CHECK:STDERR: · ┳━━━━━━━
// CHECK:STDERR: · ┗━━┫ error: cannot convert type `T` that implements `Z` into type implementing
// CHECK:STDERR: · ┃ `Y`
// CHECK:STDERR: · ┃ [ConversionFailureFacetToFacet]
// CHECK:STDERR: ╰────
// CHECK:STDERR:
T.(Y.YY)();
}
// --- fail_todo_explicit_self_impls.carbon
library "[[@TEST_NAME]]";
interface Y {
fn YY();
}
//@dump-sem-ir-begin
interface Z {
require Self impls Y;
}
//@dump-sem-ir-end
fn F(generic T: Z) {
// CHECK:STDERR: ╭─┤ fail_todo_explicit_self_impls.carbon:[[@LINE+8]]:3
// CHECK:STDERR: -> │ T.(Y.YY)();
// CHECK:STDERR: · ┳━━━━━━━
// CHECK:STDERR: · ┗━━┫ error: cannot convert type `T` that implements `Z` into type implementing
// CHECK:STDERR: · ┃ `Y`
// CHECK:STDERR: · ┃ [ConversionFailureFacetToFacet]
// CHECK:STDERR: ╰────
// CHECK:STDERR:
T.(Y.YY)();
}
// --- fail_implicit_self_no_extend_name_lookup_fails.carbon
library "[[@TEST_NAME]]";
interface Y {
fn YY();
}
interface Z {
require impls Y;
}
fn F(generic T: Z) {
// This should fail name lookup since Z does not extend Y.
//
// CHECK:STDERR: ╭─┤ fail_implicit_self_no_extend_name_lookup_fails.carbon:[[@LINE+7]]:3
// CHECK:STDERR: -> │ T.YY();
// CHECK:STDERR: · ━━┳━
// CHECK:STDERR: · ┗━━┫ error: member name `YY` not found in `Z`
// CHECK:STDERR: · ┃ [MemberNameNotFoundInSpecificScope]
// CHECK:STDERR: ╰────
// CHECK:STDERR:
T.YY();
}
// --- fail_explicit_self_no_extend_name_lookup_fails.carbon
library "[[@TEST_NAME]]";
interface Y {
fn YY();
}
interface Z {
require Self impls Y;
}
fn F(generic T: Z) {
// This should fail name lookup since Z does not extend Y.
//
// CHECK:STDERR: ╭─┤ fail_explicit_self_no_extend_name_lookup_fails.carbon:[[@LINE+7]]:3
// CHECK:STDERR: -> │ T.YY();
// CHECK:STDERR: · ━━┳━
// CHECK:STDERR: · ┗━━┫ error: member name `YY` not found in `Z`
// CHECK:STDERR: · ┃ [MemberNameNotFoundInSpecificScope]
// CHECK:STDERR: ╰────
// CHECK:STDERR:
T.YY();
}
// --- explicit_self_specific_impls.carbon
library "[[@TEST_NAME]]";
interface Y {}
class C(T: type);
//@dump-sem-ir-begin
interface Z {
require C(Self) impls Y;
}
//@dump-sem-ir-end
// --- fail_non_self_doesnt_provide_witness_for_self.carbon
library "[[@TEST_NAME]]";
interface Y {
fn YY();
}
class C(T: type);
interface Z {
require C(Self) impls Y;
}
fn F(generic T: Z) {
// This fails because `T impls Z` implies that `C(T) impls Y`, not that
// `T impls Y`.
// CHECK:STDERR: ╭─┤ fail_non_self_doesnt_provide_witness_for_self.carbon:[[@LINE+8]]:3
// CHECK:STDERR: -> │ T.(Y.YY)();
// CHECK:STDERR: · ┳━━━━━━━
// CHECK:STDERR: · ┗━━┫ error: cannot convert type `T` that implements `Z` into type implementing
// CHECK:STDERR: · ┃ `Y`
// CHECK:STDERR: · ┃ [ConversionFailureFacetToFacet]
// CHECK:STDERR: ╰────
// CHECK:STDERR:
T.(Y.YY)();
}
// --- fail_todo_non_self_provide_witness_for_non_self.carbon
library "[[@TEST_NAME]]";
interface Y {
fn YY();
}
class C(T: type);
interface Z {
require C(Self) impls Y;
}
fn F(generic T: Z) {
// CHECK:STDERR: ╭─┤ fail_todo_non_self_provide_witness_for_non_self.carbon:[[@LINE+7]]:3
// CHECK:STDERR: -> │ C(T).(Y.YY)();
// CHECK:STDERR: · ━━━━━┳━━━━━
// CHECK:STDERR: · ┗━━┫ error: cannot convert type `C(T)` into type implementing `Y`
// CHECK:STDERR: · ┃ [ConversionFailureTypeToFacet]
// CHECK:STDERR: ╰────
// CHECK:STDERR:
C(T).(Y.YY)();
}
// --- require_impls_where.carbon
library "[[@TEST_NAME]]";
interface Y { let Y1: type; }
//@dump-sem-ir-begin
interface Z {
require impls Y where .Y1 = ();
}
//@dump-sem-ir-end
// --- require_impls_self_specific.carbon
library "[[@TEST_NAME]]";
//@dump-sem-ir-begin
interface Z(T: type) {
require T impls Z(Self);
}
//@dump-sem-ir-end
// --- fail_require_impls_without_self.carbon
library "[[@TEST_NAME]]";
interface Y {
let Y1: type;
}
interface Z(T: type) {
// Either the type `T` or the facet type `Y` must mention `Self` in a way that
// it would appear in the type structure used for impl lookup (so inside a
// `where` does not count). But they don't.
//
// CHECK:STDERR: ╭─┤ fail_require_impls_without_self.carbon:[[@LINE+9]]:3
// CHECK:STDERR: -> │ require T impls Y where .Y1 = Self;
// CHECK:STDERR: · ┳━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
// CHECK:STDERR: · ┗━━┫ error: no `Self` reference found in `require` declaration; `Self` must
// CHECK:STDERR: · ┃ appear in the self-type or as a generic argument for each required
// CHECK:STDERR: · ┃ interface, but found interface `Y` without a `Self` argument
// CHECK:STDERR: · ┃ [RequireImplsMissingSelf]
// CHECK:STDERR: ╰────
// CHECK:STDERR:
require T impls Y where .Y1 = Self;
}
// --- fail_require_impls_without_self_in_one_interface.carbon
library "[[@TEST_NAME]]";
interface Y(T: type) {}
interface Z(T: type) {
// Self is in one interface but not the other.
//
// CHECK:STDERR: ╭─┤ fail_require_impls_without_self_in_one_interface.carbon:[[@LINE+9]]:3
// CHECK:STDERR: -> │ require T impls Y(Self) & Y({});
// CHECK:STDERR: · ┳━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
// CHECK:STDERR: · ┗━━┫ error: no `Self` reference found in `require` declaration; `Self` must
// CHECK:STDERR: · ┃ appear in the self-type or as a generic argument for each required
// CHECK:STDERR: · ┃ interface, but found interface `Y({})` without a `Self` argument
// CHECK:STDERR: · ┃ [RequireImplsMissingSelf]
// CHECK:STDERR: ╰────
// CHECK:STDERR:
require T impls Y(Self) & Y({});
}
// --- fail_require_impls_without_self_in_multiple_interfaces.carbon
library "[[@TEST_NAME]]";
interface Y(T: type) {}
interface Z(T: type) {
// Self does not appear in either interface, we should get an error for each.
//
// CHECK:STDERR: ╭─┤ fail_require_impls_without_self_in_multiple_interfaces.carbon:[[@LINE+18]]:3
// CHECK:STDERR: -> │ require T impls Y(()) & Y({});
// CHECK:STDERR: · ┳━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
// CHECK:STDERR: · ┗━━┫ error: no `Self` reference found in `require` declaration; `Self` must
// CHECK:STDERR: · ┃ appear in the self-type or as a generic argument for each required
// CHECK:STDERR: · ┃ interface, but found interface `Y(())` without a `Self` argument
// CHECK:STDERR: · ┃ [RequireImplsMissingSelf]
// CHECK:STDERR: ╰────
// CHECK:STDERR:
// CHECK:STDERR: ╭─┤ fail_require_impls_without_self_in_multiple_interfaces.carbon:[[@LINE+9]]:3
// CHECK:STDERR: -> │ require T impls Y(()) & Y({});
// CHECK:STDERR: · ┳━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
// CHECK:STDERR: · ┗━━┫ error: no `Self` reference found in `require` declaration; `Self` must
// CHECK:STDERR: · ┃ appear in the self-type or as a generic argument for each required
// CHECK:STDERR: · ┃ interface, but found interface `Y({})` without a `Self` argument
// CHECK:STDERR: · ┃ [RequireImplsMissingSelf]
// CHECK:STDERR: ╰────
// CHECK:STDERR:
require T impls Y(()) & Y({});
}
// --- fail_self_impls_self.carbon
library "[[@TEST_NAME]]";
interface Z(T: type) {
// CHECK:STDERR: ╭─┤ fail_self_impls_self.carbon:[[@LINE+9]]:17
// CHECK:STDERR: -> │ require impls Self;
// CHECK:STDERR: · ┳━━━
// CHECK:STDERR: · ┗━━┫ error: `require` declaration constrained by a non-facet
// CHECK:STDERR: · ┃ type; expected an `interface` or `constraint` name
// CHECK:STDERR: · ┃ after `impls`
// CHECK:STDERR: · ┃ [RequireImplsMissingFacetType]
// CHECK:STDERR: ╰────
// CHECK:STDERR:
require impls Self;
}
// --- fail_impls_type.carbon
library "[[@TEST_NAME]]";
class C(T: type) {}
interface Z(T: type) {
// CHECK:STDERR: ╭─┤ fail_impls_type.carbon:[[@LINE+9]]:19
// CHECK:STDERR: -> │ require T impls C(Self);
// CHECK:STDERR: · ┳━━━━━━
// CHECK:STDERR: · ┗━━┫ error: `require` declaration constrained by a non-facet
// CHECK:STDERR: · ┃ type; expected an `interface` or `constraint` name
// CHECK:STDERR: · ┃ after `impls`
// CHECK:STDERR: · ┃ [RequireImplsMissingFacetType]
// CHECK:STDERR: ╰────
// CHECK:STDERR:
require T impls C(Self);
}
// --- fail_non_type_impls.carbon
library "[[@TEST_NAME]]";
interface Y {}
interface Z(T: type) {
// CHECK:STDERR: ╭─┤ fail_non_type_impls.carbon:[[@LINE+8]]:11
// CHECK:STDERR: -> │ require 1 impls Y;
// CHECK:STDERR: · ┳
// CHECK:STDERR: · ┗━━┫ error: cannot implicitly convert non-type value of type
// CHECK:STDERR: · ┃ `Core.IntLiteral` to `type`
// CHECK:STDERR: · ┃ [ConversionFailureNonTypeToFacet]
// CHECK:STDERR: ╰────
// CHECK:STDERR:
require 1 impls Y;
}
// --- fail_impls_non_type.carbon
library "[[@TEST_NAME]]";
interface Y {}
interface Z(T: type) {
// CHECK:STDERR: ╭─┤ fail_impls_non_type.carbon:[[@LINE+9]]:17
// CHECK:STDERR: -> │ require impls 1;
// CHECK:STDERR: · ┳
// CHECK:STDERR: · ┗━━┫ error: `require` declaration constrained by a non-facet
// CHECK:STDERR: · ┃ type; expected an `interface` or `constraint` name
// CHECK:STDERR: · ┃ after `impls`
// CHECK:STDERR: · ┃ [RequireImplsMissingFacetType]
// CHECK:STDERR: ╰────
// CHECK:STDERR:
require impls 1;
}
// --- require_self_in_requirement.carbon
library "[[@TEST_NAME]]";
interface Y {
let Y1: type;
}
//@dump-sem-ir-begin
interface Z {
// Self can appear in a requirement.
require impls Y where .Y1 = Self;
}
//@dump-sem-ir-end
// --- require_same.carbon
library "[[@TEST_NAME]]";
interface Y {
require impls Y;
}
//@dump-sem-ir-begin
interface Z(T: type) {
// This is okay because an interface Z can be identified before it's complete,
// unlike a named constraint.
require impls Z(T);
}
//@dump-sem-ir-end
// CHECK:STDOUT: --- fail_todo_extend.carbon = $fail_todo_extend
// CHECK:STDOUT:
// CHECK:STDOUT: constants {
// CHECK:STDOUT: type: type = facet_type <type> [concrete]
// CHECK:STDOUT: %Y.type: type = facet_type <@Y> [concrete]
// CHECK:STDOUT: %Z.type: type = facet_type <@Z> [concrete]
// CHECK:STDOUT: %Self.cb6: %Z.type = symbolic_binding Self, 0 [symbolic]
// CHECK:STDOUT: %Self.as_type: type = facet_access_type %Self.cb6 [symbolic]
// CHECK:STDOUT: %T: %Z.type = symbolic_binding T, 0 [symbolic]
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: file {
// CHECK:STDOUT: %Z.decl: type = interface_decl @Z [concrete = constants.%Z.type] {} {}
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: interface @Z {
// CHECK:STDOUT: %Self: %Z.type = symbolic_binding Self, 0 [symbolic = constants.%Self.cb6]
// CHECK:STDOUT: %Z.WithSelf.decl = interface_with_self_decl @Z [concrete]
// CHECK:STDOUT:
// CHECK:STDOUT: !with Self:
// CHECK:STDOUT: %Z.WithSelf.Self.as_type.impls.Y.type.require.decl = require_decl @Z.WithSelf.Self.as_type.impls.Y.type.require [concrete] {
// CHECK:STDOUT: require %Self.as_type.loc9_18.1 impls %Y.ref
// CHECK:STDOUT: } {
// CHECK:STDOUT: %Self.as_type.loc9_18.1: type = facet_access_type @Z.%Self [symbolic = %Self.as_type.loc9_18.2 (constants.%Self.as_type)]
// CHECK:STDOUT: %Y.ref: type = name_ref Y, file.%Y.decl [concrete = constants.%Y.type]
// CHECK:STDOUT: }
// CHECK:STDOUT: %.loc9: type = specific_constant @Z.WithSelf.Self.as_type.impls.Y.type.require.%Y.ref, @Z.WithSelf.Self.as_type.impls.Y.type.require(constants.%Self.cb6) [concrete = constants.%Y.type]
// CHECK:STDOUT:
// CHECK:STDOUT: !members:
// CHECK:STDOUT: .Self = %Self
// CHECK:STDOUT: .Y = <poisoned>
// CHECK:STDOUT: .Y = <poisoned>
// CHECK:STDOUT: .YY = <poisoned>
// CHECK:STDOUT: extend @Z.WithSelf.%.loc9
// CHECK:STDOUT: witness = ()
// CHECK:STDOUT:
// CHECK:STDOUT: !requires:
// CHECK:STDOUT: @Z.WithSelf.Self.as_type.impls.Y.type.require {
// CHECK:STDOUT: require @Z.WithSelf.Self.as_type.impls.Y.type.require.%Self.as_type.loc9_18.1 impls @Z.WithSelf.Self.as_type.impls.Y.type.require.%Y.ref
// CHECK:STDOUT: }
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: generic require @Z.WithSelf.Self.as_type.impls.Y.type.require(@Z.%Self: %Z.type) {
// CHECK:STDOUT: %Self: %Z.type = symbolic_binding Self, 0 [symbolic = %Self (constants.%Self.cb6)]
// CHECK:STDOUT: %Self.as_type.loc9_18.2: type = facet_access_type %Self [symbolic = %Self.as_type.loc9_18.2 (constants.%Self.as_type)]
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: specific @Z.WithSelf(constants.%Self.cb6) {
// CHECK:STDOUT: !definition:
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: specific @Z.WithSelf.Self.as_type.impls.Y.type.require(constants.%Self.cb6) {
// CHECK:STDOUT: %Self => constants.%Self.cb6
// CHECK:STDOUT: %Self.as_type.loc9_18.2 => constants.%Self.as_type
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: specific @Z.WithSelf(constants.%T) {
// CHECK:STDOUT: !definition:
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: --- fail_todo_extend_with_self.carbon = $fail_todo_extend_with_self
// CHECK:STDOUT:
// CHECK:STDOUT: constants {
// CHECK:STDOUT: type: type = facet_type <type> [concrete]
// CHECK:STDOUT: %Y.type.cb4: type = generic_interface_type @Y [concrete]
// CHECK:STDOUT: %Y.generic: %Y.type.cb4 = struct_value () [concrete]
// CHECK:STDOUT: %Z.type: type = facet_type <@Z> [concrete]
// CHECK:STDOUT: %Self.cb6: %Z.type = symbolic_binding Self, 0 [symbolic]
// CHECK:STDOUT: %Self.as_type: type = facet_access_type %Self.cb6 [symbolic]
// CHECK:STDOUT: %Y.type.33d: type = facet_type <@Y, @Y(%Self.as_type)> [symbolic]
// CHECK:STDOUT: %require_complete.048: <witness> = require_complete_type %Y.type.33d [symbolic]
// CHECK:STDOUT: %T.013: %Z.type = symbolic_binding T, 0 [symbolic]
// CHECK:STDOUT: %T.as_type: type = facet_access_type %T.013 [symbolic]
// CHECK:STDOUT: %Y.type.0db: type = facet_type <@Y, @Y(%T.as_type)> [symbolic]
// CHECK:STDOUT: %require_complete.d69: <witness> = require_complete_type %Y.type.0db [symbolic]
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: file {
// CHECK:STDOUT: %Z.decl: type = interface_decl @Z [concrete = constants.%Z.type] {} {}
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: interface @Z {
// CHECK:STDOUT: %Self: %Z.type = symbolic_binding Self, 0 [symbolic = constants.%Self.cb6]
// CHECK:STDOUT: %Z.WithSelf.decl = interface_with_self_decl @Z [concrete]
// CHECK:STDOUT:
// CHECK:STDOUT: !with Self:
// CHECK:STDOUT: %Z.WithSelf.Self.as_type.impls.Y.type.require.decl = require_decl @Z.WithSelf.Self.as_type.impls.Y.type.require [concrete] {
// CHECK:STDOUT: require %Self.as_type.loc9_18.1 impls %Y.type.loc9_30.1
// CHECK:STDOUT: } {
// CHECK:STDOUT: %Self.as_type.loc9_18.1: type = facet_access_type @Z.%Self [symbolic = %Self.as_type.loc9_18.2 (constants.%Self.as_type)]
// CHECK:STDOUT: %Y.ref: %Y.type.cb4 = name_ref Y, file.%Y.decl [concrete = constants.%Y.generic]
// CHECK:STDOUT: %Self.ref: %Z.type = name_ref Self, @Z.%Self [symbolic = %Self (constants.%Self.cb6)]
// CHECK:STDOUT: %Self.as_type.loc9_30: type = facet_access_type %Self.ref [symbolic = %Self.as_type.loc9_18.2 (constants.%Self.as_type)]
// CHECK:STDOUT: %.loc9: type = converted %Self.ref, %Self.as_type.loc9_30 [symbolic = %Self.as_type.loc9_18.2 (constants.%Self.as_type)]
// CHECK:STDOUT: %Y.type.loc9_30.1: type = facet_type <@Y, @Y(constants.%Self.as_type)> [symbolic = %Y.type.loc9_30.2 (constants.%Y.type.33d)]
// CHECK:STDOUT: }
// CHECK:STDOUT: %.loc9: type = specific_constant @Z.WithSelf.Self.as_type.impls.Y.type.require.%Y.type.loc9_30.1, @Z.WithSelf.Self.as_type.impls.Y.type.require(constants.%Self.cb6) [symbolic = %Y.type (constants.%Y.type.33d)]
// CHECK:STDOUT:
// CHECK:STDOUT: !members:
// CHECK:STDOUT: .Self = %Self
// CHECK:STDOUT: .Y = <poisoned>
// CHECK:STDOUT: .Y = <poisoned>
// CHECK:STDOUT: .YY = <poisoned>
// CHECK:STDOUT: extend @Z.WithSelf.%.loc9
// CHECK:STDOUT: witness = ()
// CHECK:STDOUT:
// CHECK:STDOUT: !requires:
// CHECK:STDOUT: @Z.WithSelf.Self.as_type.impls.Y.type.require {
// CHECK:STDOUT: require @Z.WithSelf.Self.as_type.impls.Y.type.require.%Self.as_type.loc9_18.1 impls @Z.WithSelf.Self.as_type.impls.Y.type.require.%Y.type.loc9_30.1
// CHECK:STDOUT: }
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: generic require @Z.WithSelf.Self.as_type.impls.Y.type.require(@Z.%Self: %Z.type) {
// CHECK:STDOUT: %Self: %Z.type = symbolic_binding Self, 0 [symbolic = %Self (constants.%Self.cb6)]
// CHECK:STDOUT: %Self.as_type.loc9_18.2: type = facet_access_type %Self [symbolic = %Self.as_type.loc9_18.2 (constants.%Self.as_type)]
// CHECK:STDOUT: %Y.type.loc9_30.2: type = facet_type <@Y, @Y(%Self.as_type.loc9_18.2)> [symbolic = %Y.type.loc9_30.2 (constants.%Y.type.33d)]
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: specific @Z.WithSelf(constants.%Self.cb6) {
// CHECK:STDOUT: !definition:
// CHECK:STDOUT: %Self => constants.%Self.cb6
// CHECK:STDOUT: %Self.as_type => constants.%Self.as_type
// CHECK:STDOUT: %Y.type => constants.%Y.type.33d
// CHECK:STDOUT: %require_complete => constants.%require_complete.048
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: specific @Z.WithSelf.Self.as_type.impls.Y.type.require(constants.%Self.cb6) {
// CHECK:STDOUT: %Self => constants.%Self.cb6
// CHECK:STDOUT: %Self.as_type.loc9_18.2 => constants.%Self.as_type
// CHECK:STDOUT: %Y.type.loc9_30.2 => constants.%Y.type.33d
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: specific @Z.WithSelf(constants.%T.013) {
// CHECK:STDOUT: !definition:
// CHECK:STDOUT: %Self => constants.%T.013
// CHECK:STDOUT: %Self.as_type => constants.%T.as_type
// CHECK:STDOUT: %Y.type => constants.%Y.type.0db
// CHECK:STDOUT: %require_complete => constants.%require_complete.d69
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: --- fail_todo_implicit_self_impls.carbon = $fail_todo_implicit_self_impls
// CHECK:STDOUT:
// CHECK:STDOUT: constants {
// CHECK:STDOUT: type: type = facet_type <type> [concrete]
// CHECK:STDOUT: %Y.type: type = facet_type <@Y> [concrete]
// CHECK:STDOUT: %Z.type: type = facet_type <@Z> [concrete]
// CHECK:STDOUT: %Self.cb6: %Z.type = symbolic_binding Self, 0 [symbolic]
// CHECK:STDOUT: %Self.as_type: type = facet_access_type %Self.cb6 [symbolic]
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: file {
// CHECK:STDOUT: %Z.decl: type = interface_decl @Z [concrete = constants.%Z.type] {} {}
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: interface @Z {
// CHECK:STDOUT: %Self: %Z.type = symbolic_binding Self, 0 [symbolic = constants.%Self.cb6]
// CHECK:STDOUT: %Z.WithSelf.decl = interface_with_self_decl @Z [concrete]
// CHECK:STDOUT:
// CHECK:STDOUT: !with Self:
// CHECK:STDOUT: %Z.WithSelf.Self.as_type.impls.Y.type.require.decl = require_decl @Z.WithSelf.Self.as_type.impls.Y.type.require [concrete] {
// CHECK:STDOUT: require %Self.as_type.loc9_11.1 impls %Y.ref
// CHECK:STDOUT: } {
// CHECK:STDOUT: %Self.as_type.loc9_11.1: type = facet_access_type @Z.%Self [symbolic = %Self.as_type.loc9_11.2 (constants.%Self.as_type)]
// CHECK:STDOUT: %Y.ref: type = name_ref Y, file.%Y.decl [concrete = constants.%Y.type]
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: !members:
// CHECK:STDOUT: .Self = %Self
// CHECK:STDOUT: .Y = <poisoned>
// CHECK:STDOUT: .Y = <poisoned>
// CHECK:STDOUT: witness = ()
// CHECK:STDOUT:
// CHECK:STDOUT: !requires:
// CHECK:STDOUT: @Z.WithSelf.Self.as_type.impls.Y.type.require {
// CHECK:STDOUT: require @Z.WithSelf.Self.as_type.impls.Y.type.require.%Self.as_type.loc9_11.1 impls @Z.WithSelf.Self.as_type.impls.Y.type.require.%Y.ref
// CHECK:STDOUT: }
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: generic require @Z.WithSelf.Self.as_type.impls.Y.type.require(@Z.%Self: %Z.type) {
// CHECK:STDOUT: %Self: %Z.type = symbolic_binding Self, 0 [symbolic = %Self (constants.%Self.cb6)]
// CHECK:STDOUT: %Self.as_type.loc9_11.2: type = facet_access_type %Self [symbolic = %Self.as_type.loc9_11.2 (constants.%Self.as_type)]
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: specific @Z.WithSelf(constants.%Self.cb6) {}
// CHECK:STDOUT:
// CHECK:STDOUT: specific @Z.WithSelf.Self.as_type.impls.Y.type.require(constants.%Self.cb6) {
// CHECK:STDOUT: %Self => constants.%Self.cb6
// CHECK:STDOUT: %Self.as_type.loc9_11.2 => constants.%Self.as_type
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: --- fail_todo_explicit_self_impls.carbon = $fail_todo_explicit_self_impls
// CHECK:STDOUT:
// CHECK:STDOUT: constants {
// CHECK:STDOUT: type: type = facet_type <type> [concrete]
// CHECK:STDOUT: %Y.type: type = facet_type <@Y> [concrete]
// CHECK:STDOUT: %Z.type: type = facet_type <@Z> [concrete]
// CHECK:STDOUT: %Self.cb6: %Z.type = symbolic_binding Self, 0 [symbolic]
// CHECK:STDOUT: %Self.as_type: type = facet_access_type %Self.cb6 [symbolic]
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: file {
// CHECK:STDOUT: %Z.decl: type = interface_decl @Z [concrete = constants.%Z.type] {} {}
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: interface @Z {
// CHECK:STDOUT: %Self: %Z.type = symbolic_binding Self, 0 [symbolic = constants.%Self.cb6]
// CHECK:STDOUT: %Z.WithSelf.decl = interface_with_self_decl @Z [concrete]
// CHECK:STDOUT:
// CHECK:STDOUT: !with Self:
// CHECK:STDOUT: %Z.WithSelf.Self.as_type.impls.Y.type.require.decl = require_decl @Z.WithSelf.Self.as_type.impls.Y.type.require [concrete] {
// CHECK:STDOUT: require %.loc9 impls %Y.ref
// CHECK:STDOUT: } {
// CHECK:STDOUT: %Self.ref: %Z.type = name_ref Self, @Z.%Self [symbolic = %Self (constants.%Self.cb6)]
// CHECK:STDOUT: %Self.as_type.loc9_11.1: type = facet_access_type %Self.ref [symbolic = %Self.as_type.loc9_11.2 (constants.%Self.as_type)]
// CHECK:STDOUT: %.loc9: type = converted %Self.ref, %Self.as_type.loc9_11.1 [symbolic = %Self.as_type.loc9_11.2 (constants.%Self.as_type)]
// CHECK:STDOUT: %Y.ref: type = name_ref Y, file.%Y.decl [concrete = constants.%Y.type]
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: !members:
// CHECK:STDOUT: .Self = %Self
// CHECK:STDOUT: .Y = <poisoned>
// CHECK:STDOUT: .Y = <poisoned>
// CHECK:STDOUT: witness = ()
// CHECK:STDOUT:
// CHECK:STDOUT: !requires:
// CHECK:STDOUT: @Z.WithSelf.Self.as_type.impls.Y.type.require {
// CHECK:STDOUT: require @Z.WithSelf.Self.as_type.impls.Y.type.require.%.loc9 impls @Z.WithSelf.Self.as_type.impls.Y.type.require.%Y.ref
// CHECK:STDOUT: }
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: generic require @Z.WithSelf.Self.as_type.impls.Y.type.require(@Z.%Self: %Z.type) {
// CHECK:STDOUT: %Self: %Z.type = symbolic_binding Self, 0 [symbolic = %Self (constants.%Self.cb6)]
// CHECK:STDOUT: %Self.as_type.loc9_11.2: type = facet_access_type %Self [symbolic = %Self.as_type.loc9_11.2 (constants.%Self.as_type)]
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: specific @Z.WithSelf(constants.%Self.cb6) {}
// CHECK:STDOUT:
// CHECK:STDOUT: specific @Z.WithSelf.Self.as_type.impls.Y.type.require(constants.%Self.cb6) {
// CHECK:STDOUT: %Self => constants.%Self.cb6
// CHECK:STDOUT: %Self.as_type.loc9_11.2 => constants.%Self.as_type
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: --- explicit_self_specific_impls.carbon = $explicit_self_specific_impls
// CHECK:STDOUT:
// CHECK:STDOUT: constants {
// CHECK:STDOUT: type: type = facet_type <type> [concrete]
// CHECK:STDOUT: %Y.type: type = facet_type <@Y> [concrete]
// CHECK:STDOUT: %C.type: type = parameterized_class_name_type @C [concrete]
// CHECK:STDOUT: %C.generic: %C.type = struct_value () [concrete]
// CHECK:STDOUT: %Z.type: type = facet_type <@Z> [concrete]
// CHECK:STDOUT: %Self.cb6: %Z.type = symbolic_binding Self, 0 [symbolic]
// CHECK:STDOUT: %Self.as_type: type = facet_access_type %Self.cb6 [symbolic]
// CHECK:STDOUT: %C.4f7: type = class_type @C, @C(%Self.as_type) [symbolic]
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: file {
// CHECK:STDOUT: %Z.decl: type = interface_decl @Z [concrete = constants.%Z.type] {} {}
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: interface @Z {
// CHECK:STDOUT: %Self: %Z.type = symbolic_binding Self, 0 [symbolic = constants.%Self.cb6]
// CHECK:STDOUT: %Z.WithSelf.decl = interface_with_self_decl @Z [concrete]
// CHECK:STDOUT:
// CHECK:STDOUT: !with Self:
// CHECK:STDOUT: %Z.WithSelf.C.impls.Y.type.require.decl = require_decl @Z.WithSelf.C.impls.Y.type.require [concrete] {
// CHECK:STDOUT: require %C.loc9_17.1 impls %Y.ref
// CHECK:STDOUT: } {
// CHECK:STDOUT: %C.ref: %C.type = name_ref C, file.%C.decl [concrete = constants.%C.generic]
// CHECK:STDOUT: %Self.ref: %Z.type = name_ref Self, @Z.%Self [symbolic = %Self (constants.%Self.cb6)]
// CHECK:STDOUT: %Self.as_type.loc9_17.1: type = facet_access_type %Self.ref [symbolic = %Self.as_type.loc9_17.2 (constants.%Self.as_type)]
// CHECK:STDOUT: %.loc9: type = converted %Self.ref, %Self.as_type.loc9_17.1 [symbolic = %Self.as_type.loc9_17.2 (constants.%Self.as_type)]
// CHECK:STDOUT: %C.loc9_17.1: type = class_type @C, @C(constants.%Self.as_type) [symbolic = %C.loc9_17.2 (constants.%C.4f7)]
// CHECK:STDOUT: %Y.ref: type = name_ref Y, file.%Y.decl [concrete = constants.%Y.type]
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: !members:
// CHECK:STDOUT: .Self = %Self
// CHECK:STDOUT: .C = <poisoned>
// CHECK:STDOUT: .Y = <poisoned>
// CHECK:STDOUT: .C = <poisoned>
// CHECK:STDOUT: .Y = <poisoned>
// CHECK:STDOUT: witness = ()
// CHECK:STDOUT:
// CHECK:STDOUT: !requires:
// CHECK:STDOUT: @Z.WithSelf.C.impls.Y.type.require {
// CHECK:STDOUT: require @Z.WithSelf.C.impls.Y.type.require.%C.loc9_17.1 impls @Z.WithSelf.C.impls.Y.type.require.%Y.ref
// CHECK:STDOUT: }
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: generic require @Z.WithSelf.C.impls.Y.type.require(@Z.%Self: %Z.type) {
// CHECK:STDOUT: %Self: %Z.type = symbolic_binding Self, 0 [symbolic = %Self (constants.%Self.cb6)]
// CHECK:STDOUT: %Self.as_type.loc9_17.2: type = facet_access_type %Self [symbolic = %Self.as_type.loc9_17.2 (constants.%Self.as_type)]
// CHECK:STDOUT: %C.loc9_17.2: type = class_type @C, @C(%Self.as_type.loc9_17.2) [symbolic = %C.loc9_17.2 (constants.%C.4f7)]
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: specific @Z.WithSelf(constants.%Self.cb6) {}
// CHECK:STDOUT:
// CHECK:STDOUT: specific @Z.WithSelf.C.impls.Y.type.require(constants.%Self.cb6) {
// CHECK:STDOUT: %Self => constants.%Self.cb6
// CHECK:STDOUT: %Self.as_type.loc9_17.2 => constants.%Self.as_type
// CHECK:STDOUT: %C.loc9_17.2 => constants.%C.4f7
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: --- require_impls_where.carbon = $require_impls_where
// CHECK:STDOUT:
// CHECK:STDOUT: constants {
// CHECK:STDOUT: type: type = facet_type <type> [concrete]
// CHECK:STDOUT: %Y.type: type = facet_type <@Y> [concrete]
// CHECK:STDOUT: %Y.assoc_type: type = assoc_entity_type @Y [concrete]
// CHECK:STDOUT: %assoc0: %Y.assoc_type = assoc_entity element0, @Y.WithSelf.%Y1 [concrete]
// CHECK:STDOUT: %Z.type: type = facet_type <@Z> [concrete]
// CHECK:STDOUT: %Self.cb6: %Z.type = symbolic_binding Self, 0 [symbolic]
// CHECK:STDOUT: %Self.as_type: type = facet_access_type %Self.cb6 [symbolic]
// CHECK:STDOUT: %.Self.frozen: %Y.type = symbolic_binding .Self [symbolic_self]
// CHECK:STDOUT: %.Self.frozen.as_type: type = facet_access_type %.Self.frozen [symbolic_self]
// CHECK:STDOUT: %Y.lookup_impl_witness.94c: <witness> = lookup_impl_witness %.Self.frozen, @Y [symbolic_self]
// CHECK:STDOUT: %impl.elem0.74a: type = impl_witness_access %Y.lookup_impl_witness.94c, element0 [symbolic_self]
// CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [concrete]
// CHECK:STDOUT: %empty_tuple: %empty_tuple.type = tuple_value () [concrete]
// CHECK:STDOUT: %.Self: %Y.type = symbolic_binding .Self [symbolic_self]
// CHECK:STDOUT: %Y.lookup_impl_witness.9c7: <witness> = lookup_impl_witness %.Self, @Y [symbolic_self]
// CHECK:STDOUT: %impl.elem0.591: type = impl_witness_access %Y.lookup_impl_witness.9c7, element0 [symbolic_self]
// CHECK:STDOUT: %Y_where.type.193: type = facet_type <@Y where %impl.elem0.591 = %empty_tuple.type> [concrete]
// CHECK:STDOUT: %Y.lookup_impl_witness.253: <witness> = lookup_impl_witness %Self.cb6, @Y [symbolic]
// CHECK:STDOUT: %impl.elem0.060: type = impl_witness_access %Y.lookup_impl_witness.253, element0 [symbolic]
// CHECK:STDOUT: %Y_where.type.bc8: type = facet_type <@Y where %impl.elem0.060 = %empty_tuple.type> [symbolic]
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: file {
// CHECK:STDOUT: %Z.decl: type = interface_decl @Z [concrete = constants.%Z.type] {} {}
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: interface @Z {
// CHECK:STDOUT: %Self: %Z.type = symbolic_binding Self, 0 [symbolic = constants.%Self.cb6]
// CHECK:STDOUT: %Z.WithSelf.decl = interface_with_self_decl @Z [concrete]
// CHECK:STDOUT:
// CHECK:STDOUT: !with Self:
// CHECK:STDOUT: %Z.WithSelf.Self.as_type.impls.Y_where.type.require.decl = require_decl @Z.WithSelf.Self.as_type.impls.Y_where.type.require [concrete] {
// CHECK:STDOUT: require %Self.as_type.loc7_11.1 impls %Y_where.type.loc7_19.1
// CHECK:STDOUT: } {
// CHECK:STDOUT: %Self.as_type.loc7_11.1: type = facet_access_type @Z.%Self [symbolic = %Self.as_type.loc7_11.2 (constants.%Self.as_type)]
// CHECK:STDOUT: %Y.ref: type = name_ref Y, file.%Y.decl [concrete = constants.%Y.type]
// CHECK:STDOUT: %.Self.frozen: %Y.type = symbolic_binding .Self [symbolic_self = constants.%.Self.frozen]
// CHECK:STDOUT: %base_facet_type = requirement_base_facet_type %Y.ref [concrete]
// CHECK:STDOUT: %.Self.ref: %Y.type = name_ref .Self, %.Self.frozen [symbolic_self = constants.%.Self.frozen]
// CHECK:STDOUT: %.Self.as_type: type = facet_access_type %.Self.ref [symbolic_self = constants.%.Self.frozen.as_type]
// CHECK:STDOUT: %.loc7_25: type = converted %.Self.ref, %.Self.as_type [symbolic_self = constants.%.Self.frozen.as_type]
// CHECK:STDOUT: %Y1.ref: %Y.assoc_type = name_ref Y1, @Y1.%assoc0 [concrete = constants.%assoc0]
// CHECK:STDOUT: %impl.elem0.loc7_25.1: type = impl_witness_access constants.%Y.lookup_impl_witness.94c, element0 [symbolic_self = constants.%impl.elem0.74a]
// CHECK:STDOUT: %.loc7_32.1: %empty_tuple.type = tuple_literal () [concrete = constants.%empty_tuple]
// CHECK:STDOUT: %.loc7_32.2: type = converted %.loc7_32.1, constants.%empty_tuple.type [concrete = constants.%empty_tuple.type]
// CHECK:STDOUT: %rewrite.loc7_29.1 = requirement_rewrite %impl.elem0.loc7_25.1, %.loc7_32.2 [concrete]
// CHECK:STDOUT: %impl.elem0.loc7_25.2: type = impl_witness_access constants.%Y.lookup_impl_witness.9c7, element0 [symbolic_self = constants.%impl.elem0.591]
// CHECK:STDOUT: %rewrite.loc7_29.2 = requirement_rewrite %impl.elem0.loc7_25.2, %.loc7_32.2 [concrete]
// CHECK:STDOUT: %.loc7_19: type = where_expr [concrete = constants.%Y_where.type.193] {
// CHECK:STDOUT: %base_facet_type = requirement_base_facet_type %Y.ref [concrete]
// CHECK:STDOUT: %rewrite.loc7_29.2 = requirement_rewrite %impl.elem0.loc7_25.2, %.loc7_32.2 [concrete]
// CHECK:STDOUT: }
// CHECK:STDOUT: %Y_where.type.loc7_19.1: type = facet_type <@Y where constants.%impl.elem0.060 = constants.%empty_tuple.type> [symbolic = %Y_where.type.loc7_19.2 (constants.%Y_where.type.bc8)]
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: !members:
// CHECK:STDOUT: .Self = %Self
// CHECK:STDOUT: .Y = <poisoned>
// CHECK:STDOUT: .Y = <poisoned>
// CHECK:STDOUT: witness = ()
// CHECK:STDOUT:
// CHECK:STDOUT: !requires:
// CHECK:STDOUT: @Z.WithSelf.Self.as_type.impls.Y_where.type.require {
// CHECK:STDOUT: require @Z.WithSelf.Self.as_type.impls.Y_where.type.require.%Self.as_type.loc7_11.1 impls @Z.WithSelf.Self.as_type.impls.Y_where.type.require.%Y_where.type.loc7_19.1
// CHECK:STDOUT: }
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: generic require @Z.WithSelf.Self.as_type.impls.Y_where.type.require(@Z.%Self: %Z.type) {
// CHECK:STDOUT: %Self: %Z.type = symbolic_binding Self, 0 [symbolic = %Self (constants.%Self.cb6)]
// CHECK:STDOUT: %Self.as_type.loc7_11.2: type = facet_access_type %Self [symbolic = %Self.as_type.loc7_11.2 (constants.%Self.as_type)]
// CHECK:STDOUT: %Y.lookup_impl_witness: <witness> = lookup_impl_witness %Self, @Y [symbolic = %Y.lookup_impl_witness (constants.%Y.lookup_impl_witness.253)]
// CHECK:STDOUT: %impl.elem0.loc7_19: type = impl_witness_access %Y.lookup_impl_witness, element0 [symbolic = %impl.elem0.loc7_19 (constants.%impl.elem0.060)]
// CHECK:STDOUT: %Y_where.type.loc7_19.2: type = facet_type <@Y where %impl.elem0.loc7_19 = constants.%empty_tuple.type> [symbolic = %Y_where.type.loc7_19.2 (constants.%Y_where.type.bc8)]
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: specific @Z.WithSelf(constants.%Self.cb6) {}
// CHECK:STDOUT:
// CHECK:STDOUT: specific @Z.WithSelf.Self.as_type.impls.Y_where.type.require(constants.%Self.cb6) {
// CHECK:STDOUT: %Self => constants.%Self.cb6
// CHECK:STDOUT: %Self.as_type.loc7_11.2 => constants.%Self.as_type
// CHECK:STDOUT: %Y.lookup_impl_witness => constants.%Y.lookup_impl_witness.253
// CHECK:STDOUT: %impl.elem0.loc7_19 => constants.%impl.elem0.060
// CHECK:STDOUT: %Y_where.type.loc7_19.2 => constants.%Y_where.type.bc8
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: --- require_impls_self_specific.carbon = $require_impls_self_specific
// CHECK:STDOUT:
// CHECK:STDOUT: constants {
// CHECK:STDOUT: type: type = facet_type <type> [concrete]
// CHECK:STDOUT: %.Self.frozen: type = symbolic_binding .Self [symbolic_self]
// CHECK:STDOUT: %pattern_type: type = pattern_type type [concrete]
// CHECK:STDOUT: %T.patt: %pattern_type = symbolic_binding_pattern T, 0 [symbolic]
// CHECK:STDOUT: %T: type = symbolic_binding T, 0 [symbolic]
// CHECK:STDOUT: %Z.type.c39: type = generic_interface_type @Z [concrete]
// CHECK:STDOUT: %Z.generic: %Z.type.c39 = struct_value () [concrete]
// CHECK:STDOUT: %Z.type.c5f: type = facet_type <@Z, @Z(%T)> [symbolic]
// CHECK:STDOUT: %Self: %Z.type.c5f = symbolic_binding Self, 1 [symbolic]
// CHECK:STDOUT: %Self.as_type: type = facet_access_type %Self [symbolic]
// CHECK:STDOUT: %Z.type.833: type = facet_type <@Z, @Z(%Self.as_type)> [symbolic]
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: file {
// CHECK:STDOUT: %Z.decl: %Z.type.c39 = interface_decl @Z [concrete = constants.%Z.generic] {
// CHECK:STDOUT: %T.patt.loc4_14.1: %pattern_type = symbolic_binding_pattern T, 0 [symbolic = %T.patt.loc4_14.2 (constants.%T.patt)]
// CHECK:STDOUT: } {
// CHECK:STDOUT: %.loc4_16.1: type = splice_block %.loc4_16.2 [concrete = type] {
// CHECK:STDOUT: %.Self.frozen: type = symbolic_binding .Self [symbolic_self = constants.%.Self.frozen]
// CHECK:STDOUT: %.loc4_16.2: type = type_literal type [concrete = type]
// CHECK:STDOUT: }
// CHECK:STDOUT: %T.loc4_14.2: type = symbolic_binding T, 0 [symbolic = %T.loc4_14.1 (constants.%T)]
// CHECK:STDOUT: }
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: generic interface @Z(%T.loc4_14.2: type) {
// CHECK:STDOUT: %T.patt.loc4_14.2: %pattern_type = symbolic_binding_pattern T, 0 [symbolic = %T.patt.loc4_14.2 (constants.%T.patt)]
// CHECK:STDOUT: %T.loc4_14.1: type = symbolic_binding T, 0 [symbolic = %T.loc4_14.1 (constants.%T)]
// CHECK:STDOUT:
// CHECK:STDOUT: !definition:
// CHECK:STDOUT: %Z.type: type = facet_type <@Z, @Z(%T.loc4_14.1)> [symbolic = %Z.type (constants.%Z.type.c5f)]
// CHECK:STDOUT: %Self.loc4_22.2: @Z.%Z.type (%Z.type.c5f) = symbolic_binding Self, 1 [symbolic = %Self.loc4_22.2 (constants.%Self)]
// CHECK:STDOUT:
// CHECK:STDOUT: interface {
// CHECK:STDOUT: %Self.loc4_22.1: @Z.%Z.type (%Z.type.c5f) = symbolic_binding Self, 1 [symbolic = %Self.loc4_22.2 (constants.%Self)]
// CHECK:STDOUT: %Z.WithSelf.decl = interface_with_self_decl @Z [concrete]
// CHECK:STDOUT:
// CHECK:STDOUT: !with Self:
// CHECK:STDOUT: %Z.WithSelf.T.impls.Z.type.require.decl = require_decl @Z.WithSelf.T.impls.Z.type.require [concrete] {
// CHECK:STDOUT: require %T.ref impls %Z.type.loc5_25.1
// CHECK:STDOUT: } {
// CHECK:STDOUT: %.loc5_11: type = specific_constant @Z.%T.loc4_14.2, @Z(constants.%T) [symbolic = %T (constants.%T)]
// CHECK:STDOUT: %T.ref: type = name_ref T, %.loc5_11 [symbolic = %T (constants.%T)]
// CHECK:STDOUT: %Z.ref: %Z.type.c39 = name_ref Z, file.%Z.decl [concrete = constants.%Z.generic]
// CHECK:STDOUT: %.loc5_21: @Z.WithSelf.T.impls.Z.type.require.%Z.type.loc5_21 (%Z.type.c5f) = specific_constant @Z.%Self.loc4_22.1, @Z(constants.%T) [symbolic = %Self (constants.%Self)]
// CHECK:STDOUT: %Self.ref: @Z.WithSelf.T.impls.Z.type.require.%Z.type.loc5_21 (%Z.type.c5f) = name_ref Self, %.loc5_21 [symbolic = %Self (constants.%Self)]
// CHECK:STDOUT: %Self.as_type.loc5_25.1: type = facet_access_type %Self.ref [symbolic = %Self.as_type.loc5_25.2 (constants.%Self.as_type)]
// CHECK:STDOUT: %.loc5_25: type = converted %Self.ref, %Self.as_type.loc5_25.1 [symbolic = %Self.as_type.loc5_25.2 (constants.%Self.as_type)]
// CHECK:STDOUT: %Z.type.loc5_25.1: type = facet_type <@Z, @Z(constants.%Self.as_type)> [symbolic = %Z.type.loc5_25.2 (constants.%Z.type.833)]
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: !members:
// CHECK:STDOUT: .Self = %Self.loc4_22.1
// CHECK:STDOUT: .T = <poisoned>
// CHECK:STDOUT: .Z = <poisoned>
// CHECK:STDOUT: .T = <poisoned>
// CHECK:STDOUT: .Z = <poisoned>
// CHECK:STDOUT: witness = ()
// CHECK:STDOUT:
// CHECK:STDOUT: !requires:
// CHECK:STDOUT: @Z.WithSelf.T.impls.Z.type.require {
// CHECK:STDOUT: require @Z.WithSelf.T.impls.Z.type.require.%T.ref impls @Z.WithSelf.T.impls.Z.type.require.%Z.type.loc5_25.1
// CHECK:STDOUT: }
// CHECK:STDOUT: }
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: generic require @Z.WithSelf.T.impls.Z.type.require(@Z.%T.loc4_14.2: type, @Z.%Self.loc4_22.1: @Z.%Z.type (%Z.type.c5f)) {
// CHECK:STDOUT: %T: type = symbolic_binding T, 0 [symbolic = %T (constants.%T)]
// CHECK:STDOUT: %Z.type.loc5_21: type = facet_type <@Z, @Z(%T)> [symbolic = %Z.type.loc5_21 (constants.%Z.type.c5f)]
// CHECK:STDOUT: %Self: @Z.WithSelf.T.impls.Z.type.require.%Z.type.loc5_21 (%Z.type.c5f) = symbolic_binding Self, 1 [symbolic = %Self (constants.%Self)]
// CHECK:STDOUT: %Self.as_type.loc5_25.2: type = facet_access_type %Self [symbolic = %Self.as_type.loc5_25.2 (constants.%Self.as_type)]
// CHECK:STDOUT: %Z.type.loc5_25.2: type = facet_type <@Z, @Z(%Self.as_type.loc5_25.2)> [symbolic = %Z.type.loc5_25.2 (constants.%Z.type.833)]
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: specific @Z(constants.%T) {
// CHECK:STDOUT: %T.patt.loc4_14.2 => constants.%T.patt
// CHECK:STDOUT: %T.loc4_14.1 => constants.%T
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: specific @Z.WithSelf(constants.%T, constants.%Self) {}
// CHECK:STDOUT:
// CHECK:STDOUT: specific @Z(constants.%Self.as_type) {
// CHECK:STDOUT: %T.patt.loc4_14.2 => constants.%T.patt
// CHECK:STDOUT: %T.loc4_14.1 => constants.%Self.as_type
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: specific @Z.WithSelf.T.impls.Z.type.require(constants.%T, constants.%Self) {
// CHECK:STDOUT: %T => constants.%T
// CHECK:STDOUT: %Z.type.loc5_21 => constants.%Z.type.c5f
// CHECK:STDOUT: %Self => constants.%Self
// CHECK:STDOUT: %Self.as_type.loc5_25.2 => constants.%Self.as_type
// CHECK:STDOUT: %Z.type.loc5_25.2 => constants.%Z.type.833
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: --- require_self_in_requirement.carbon = $require_self_in_requirement
// CHECK:STDOUT:
// CHECK:STDOUT: constants {
// CHECK:STDOUT: type: type = facet_type <type> [concrete]
// CHECK:STDOUT: %Y.type: type = facet_type <@Y> [concrete]
// CHECK:STDOUT: %Y.assoc_type: type = assoc_entity_type @Y [concrete]
// CHECK:STDOUT: %assoc0: %Y.assoc_type = assoc_entity element0, @Y.WithSelf.%Y1 [concrete]
// CHECK:STDOUT: %Z.type: type = facet_type <@Z> [concrete]
// CHECK:STDOUT: %Self.cb6: %Z.type = symbolic_binding Self, 0 [symbolic]
// CHECK:STDOUT: %Self.as_type: type = facet_access_type %Self.cb6 [symbolic]
// CHECK:STDOUT: %.Self.frozen: %Y.type = symbolic_binding .Self [symbolic_self]
// CHECK:STDOUT: %.Self.frozen.as_type: type = facet_access_type %.Self.frozen [symbolic_self]
// CHECK:STDOUT: %Y.lookup_impl_witness.94c: <witness> = lookup_impl_witness %.Self.frozen, @Y [symbolic_self]
// CHECK:STDOUT: %impl.elem0.74a: type = impl_witness_access %Y.lookup_impl_witness.94c, element0 [symbolic_self]
// CHECK:STDOUT: %.Self: %Y.type = symbolic_binding .Self [symbolic_self]
// CHECK:STDOUT: %Y.lookup_impl_witness.9c7: <witness> = lookup_impl_witness %.Self, @Y [symbolic_self]
// CHECK:STDOUT: %impl.elem0.591: type = impl_witness_access %Y.lookup_impl_witness.9c7, element0 [symbolic_self]
// CHECK:STDOUT: %Y_where.type.d91: type = facet_type <@Y where %impl.elem0.591 = %Self.as_type> [symbolic]
// CHECK:STDOUT: %Y.lookup_impl_witness.253: <witness> = lookup_impl_witness %Self.cb6, @Y [symbolic]
// CHECK:STDOUT: %impl.elem0.060: type = impl_witness_access %Y.lookup_impl_witness.253, element0 [symbolic]
// CHECK:STDOUT: %Y_where.type.061: type = facet_type <@Y where %impl.elem0.060 = %Self.as_type> [symbolic]
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: file {
// CHECK:STDOUT: %Z.decl: type = interface_decl @Z [concrete = constants.%Z.type] {} {}
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: interface @Z {
// CHECK:STDOUT: %Self: %Z.type = symbolic_binding Self, 0 [symbolic = constants.%Self.cb6]
// CHECK:STDOUT: %Z.WithSelf.decl = interface_with_self_decl @Z [concrete]
// CHECK:STDOUT:
// CHECK:STDOUT: !with Self:
// CHECK:STDOUT: %Z.WithSelf.Self.as_type.impls.Y_where.type.require.decl = require_decl @Z.WithSelf.Self.as_type.impls.Y_where.type.require [concrete] {
// CHECK:STDOUT: require %Self.as_type.loc10_11.1 impls %Y_where.type.loc10_19.1
// CHECK:STDOUT: } {
// CHECK:STDOUT: %Self.as_type.loc10_11.1: type = facet_access_type @Z.%Self [symbolic = %Self.as_type.loc10_11.2 (constants.%Self.as_type)]
// CHECK:STDOUT: %Y.ref: type = name_ref Y, file.%Y.decl [concrete = constants.%Y.type]
// CHECK:STDOUT: %.Self.frozen: %Y.type = symbolic_binding .Self [symbolic_self = constants.%.Self.frozen]
// CHECK:STDOUT: %base_facet_type = requirement_base_facet_type %Y.ref [concrete]
// CHECK:STDOUT: %.Self.ref: %Y.type = name_ref .Self, %.Self.frozen [symbolic_self = constants.%.Self.frozen]
// CHECK:STDOUT: %.Self.as_type: type = facet_access_type %.Self.ref [symbolic_self = constants.%.Self.frozen.as_type]
// CHECK:STDOUT: %.loc10_25: type = converted %.Self.ref, %.Self.as_type [symbolic_self = constants.%.Self.frozen.as_type]
// CHECK:STDOUT: %Y1.ref: %Y.assoc_type = name_ref Y1, @Y1.%assoc0 [concrete = constants.%assoc0]
// CHECK:STDOUT: %impl.elem0.loc10_25.1: type = impl_witness_access constants.%Y.lookup_impl_witness.94c, element0 [symbolic_self = constants.%impl.elem0.74a]
// CHECK:STDOUT: %Self.ref: %Z.type = name_ref Self, @Z.%Self [symbolic = constants.%Self.cb6]
// CHECK:STDOUT: %Self.as_type.loc10_31: type = facet_access_type %Self.ref [symbolic = constants.%Self.as_type]
// CHECK:STDOUT: %.loc10_31: type = converted %Self.ref, %Self.as_type.loc10_31 [symbolic = constants.%Self.as_type]
// CHECK:STDOUT: %rewrite.loc10_29.1 = requirement_rewrite %impl.elem0.loc10_25.1, %.loc10_31 [concrete]
// CHECK:STDOUT: %impl.elem0.loc10_25.2: type = impl_witness_access constants.%Y.lookup_impl_witness.9c7, element0 [symbolic_self = constants.%impl.elem0.591]
// CHECK:STDOUT: %rewrite.loc10_29.2 = requirement_rewrite %impl.elem0.loc10_25.2, %.loc10_31 [concrete]
// CHECK:STDOUT: %.loc10_19: type = where_expr [symbolic = %Y_where.type.loc10_19.2 (constants.%Y_where.type.d91)] {
// CHECK:STDOUT: %base_facet_type = requirement_base_facet_type %Y.ref [concrete]
// CHECK:STDOUT: %rewrite.loc10_29.2 = requirement_rewrite %impl.elem0.loc10_25.2, %.loc10_31 [concrete]
// CHECK:STDOUT: }
// CHECK:STDOUT: %Y_where.type.loc10_19.1: type = facet_type <@Y where constants.%impl.elem0.060 = constants.%Self.as_type> [symbolic = %Y_where.type.loc10_19.3 (constants.%Y_where.type.061)]
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: !members:
// CHECK:STDOUT: .Self = %Self
// CHECK:STDOUT: .Y = <poisoned>
// CHECK:STDOUT: .Y = <poisoned>
// CHECK:STDOUT: witness = ()
// CHECK:STDOUT:
// CHECK:STDOUT: !requires:
// CHECK:STDOUT: @Z.WithSelf.Self.as_type.impls.Y_where.type.require {
// CHECK:STDOUT: require @Z.WithSelf.Self.as_type.impls.Y_where.type.require.%Self.as_type.loc10_11.1 impls @Z.WithSelf.Self.as_type.impls.Y_where.type.require.%Y_where.type.loc10_19.1
// CHECK:STDOUT: }
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: generic require @Z.WithSelf.Self.as_type.impls.Y_where.type.require(@Z.%Self: %Z.type) {
// CHECK:STDOUT: %Self: %Z.type = symbolic_binding Self, 0 [symbolic = %Self (constants.%Self.cb6)]
// CHECK:STDOUT: %Self.as_type.loc10_11.2: type = facet_access_type %Self [symbolic = %Self.as_type.loc10_11.2 (constants.%Self.as_type)]
// CHECK:STDOUT: %Y_where.type.loc10_19.2: type = facet_type <@Y where constants.%impl.elem0.591 = %Self.as_type.loc10_11.2> [symbolic = %Y_where.type.loc10_19.2 (constants.%Y_where.type.d91)]
// CHECK:STDOUT: %Y.lookup_impl_witness: <witness> = lookup_impl_witness %Self, @Y [symbolic = %Y.lookup_impl_witness (constants.%Y.lookup_impl_witness.253)]
// CHECK:STDOUT: %impl.elem0.loc10_19: type = impl_witness_access %Y.lookup_impl_witness, element0 [symbolic = %impl.elem0.loc10_19 (constants.%impl.elem0.060)]
// CHECK:STDOUT: %Y_where.type.loc10_19.3: type = facet_type <@Y where %impl.elem0.loc10_19 = %Self.as_type.loc10_11.2> [symbolic = %Y_where.type.loc10_19.3 (constants.%Y_where.type.061)]
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: specific @Z.WithSelf(constants.%Self.cb6) {}
// CHECK:STDOUT:
// CHECK:STDOUT: specific @Z.WithSelf.Self.as_type.impls.Y_where.type.require(constants.%Self.cb6) {
// CHECK:STDOUT: %Self => constants.%Self.cb6
// CHECK:STDOUT: %Self.as_type.loc10_11.2 => constants.%Self.as_type
// CHECK:STDOUT: %Y_where.type.loc10_19.2 => constants.%Y_where.type.d91
// CHECK:STDOUT: %Y.lookup_impl_witness => constants.%Y.lookup_impl_witness.253
// CHECK:STDOUT: %impl.elem0.loc10_19 => constants.%impl.elem0.060
// CHECK:STDOUT: %Y_where.type.loc10_19.3 => constants.%Y_where.type.061
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: --- require_same.carbon = $require_same
// CHECK:STDOUT:
// CHECK:STDOUT: constants {
// CHECK:STDOUT: type: type = facet_type <type> [concrete]
// CHECK:STDOUT: %.Self.frozen: type = symbolic_binding .Self [symbolic_self]
// CHECK:STDOUT: %pattern_type: type = pattern_type type [concrete]
// CHECK:STDOUT: %T.patt: %pattern_type = symbolic_binding_pattern T, 0 [symbolic]
// CHECK:STDOUT: %T: type = symbolic_binding T, 0 [symbolic]
// CHECK:STDOUT: %Z.type.c39: type = generic_interface_type @Z [concrete]
// CHECK:STDOUT: %Z.generic: %Z.type.c39 = struct_value () [concrete]
// CHECK:STDOUT: %Z.type.c5f: type = facet_type <@Z, @Z(%T)> [symbolic]
// CHECK:STDOUT: %Self.dd6: %Z.type.c5f = symbolic_binding Self, 1 [symbolic]
// CHECK:STDOUT: %Self.as_type.709: type = facet_access_type %Self.dd6 [symbolic]
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: file {
// CHECK:STDOUT: %Z.decl: %Z.type.c39 = interface_decl @Z [concrete = constants.%Z.generic] {
// CHECK:STDOUT: %T.patt.loc8_14.1: %pattern_type = symbolic_binding_pattern T, 0 [symbolic = %T.patt.loc8_14.2 (constants.%T.patt)]
// CHECK:STDOUT: } {
// CHECK:STDOUT: %.loc8_16.1: type = splice_block %.loc8_16.2 [concrete = type] {
// CHECK:STDOUT: %.Self.frozen: type = symbolic_binding .Self [symbolic_self = constants.%.Self.frozen]
// CHECK:STDOUT: %.loc8_16.2: type = type_literal type [concrete = type]
// CHECK:STDOUT: }
// CHECK:STDOUT: %T.loc8_14.2: type = symbolic_binding T, 0 [symbolic = %T.loc8_14.1 (constants.%T)]
// CHECK:STDOUT: }
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: generic interface @Z(%T.loc8_14.2: type) {
// CHECK:STDOUT: %T.patt.loc8_14.2: %pattern_type = symbolic_binding_pattern T, 0 [symbolic = %T.patt.loc8_14.2 (constants.%T.patt)]
// CHECK:STDOUT: %T.loc8_14.1: type = symbolic_binding T, 0 [symbolic = %T.loc8_14.1 (constants.%T)]
// CHECK:STDOUT:
// CHECK:STDOUT: !definition:
// CHECK:STDOUT: %Z.type: type = facet_type <@Z, @Z(%T.loc8_14.1)> [symbolic = %Z.type (constants.%Z.type.c5f)]
// CHECK:STDOUT: %Self.loc8_22.2: @Z.%Z.type (%Z.type.c5f) = symbolic_binding Self, 1 [symbolic = %Self.loc8_22.2 (constants.%Self.dd6)]
// CHECK:STDOUT:
// CHECK:STDOUT: interface {
// CHECK:STDOUT: %Self.loc8_22.1: @Z.%Z.type (%Z.type.c5f) = symbolic_binding Self, 1 [symbolic = %Self.loc8_22.2 (constants.%Self.dd6)]
// CHECK:STDOUT: %Z.WithSelf.decl = interface_with_self_decl @Z [concrete]
// CHECK:STDOUT:
// CHECK:STDOUT: !with Self:
// CHECK:STDOUT: %Z.WithSelf.Self.as_type.impls.Z.type.require.decl = require_decl @Z.WithSelf.Self.as_type.impls.Z.type.require [concrete] {
// CHECK:STDOUT: require %Self.as_type.loc11_11.1 impls %Z.type.loc11_20
// CHECK:STDOUT: } {
// CHECK:STDOUT: %Self.as_type.loc11_11.1: type = facet_access_type @Z.%Self.loc8_22.1 [symbolic = %Self.as_type.loc11_11.2 (constants.%Self.as_type.709)]
// CHECK:STDOUT: %Z.ref: %Z.type.c39 = name_ref Z, file.%Z.decl [concrete = constants.%Z.generic]
// CHECK:STDOUT: %.loc11: type = specific_constant @Z.%T.loc8_14.2, @Z(constants.%T) [symbolic = %T (constants.%T)]
// CHECK:STDOUT: %T.ref: type = name_ref T, %.loc11 [symbolic = %T (constants.%T)]
// CHECK:STDOUT: %Z.type.loc11_20: type = facet_type <@Z, @Z(constants.%T)> [symbolic = %Z.type.loc11_11 (constants.%Z.type.c5f)]
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: !members:
// CHECK:STDOUT: .Self = %Self.loc8_22.1
// CHECK:STDOUT: .Z = <poisoned>
// CHECK:STDOUT: .T = <poisoned>
// CHECK:STDOUT: .Z = <poisoned>
// CHECK:STDOUT: .T = <poisoned>
// CHECK:STDOUT: witness = ()
// CHECK:STDOUT:
// CHECK:STDOUT: !requires:
// CHECK:STDOUT: @Z.WithSelf.Self.as_type.impls.Z.type.require {
// CHECK:STDOUT: require @Z.WithSelf.Self.as_type.impls.Z.type.require.%Self.as_type.loc11_11.1 impls @Z.WithSelf.Self.as_type.impls.Z.type.require.%Z.type.loc11_20
// CHECK:STDOUT: }
// CHECK:STDOUT: }
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: generic require @Z.WithSelf.Self.as_type.impls.Z.type.require(@Z.%T.loc8_14.2: type, @Z.%Self.loc8_22.1: @Z.%Z.type (%Z.type.c5f)) {
// CHECK:STDOUT: %T: type = symbolic_binding T, 0 [symbolic = %T (constants.%T)]
// CHECK:STDOUT: %Z.type.loc11_11: type = facet_type <@Z, @Z(%T)> [symbolic = %Z.type.loc11_11 (constants.%Z.type.c5f)]
// CHECK:STDOUT: %Self: @Z.WithSelf.Self.as_type.impls.Z.type.require.%Z.type.loc11_11 (%Z.type.c5f) = symbolic_binding Self, 1 [symbolic = %Self (constants.%Self.dd6)]
// CHECK:STDOUT: %Self.as_type.loc11_11.2: type = facet_access_type %Self [symbolic = %Self.as_type.loc11_11.2 (constants.%Self.as_type.709)]
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: specific @Z(constants.%T) {
// CHECK:STDOUT: %T.patt.loc8_14.2 => constants.%T.patt
// CHECK:STDOUT: %T.loc8_14.1 => constants.%T
// CHECK:STDOUT: }
// CHECK:STDOUT:
// CHECK:STDOUT: specific @Z.WithSelf(constants.%T, constants.%Self.dd6) {}
// CHECK:STDOUT:
// CHECK:STDOUT: specific @Z.WithSelf.Self.as_type.impls.Z.type.require(constants.%T, constants.%Self.dd6) {
// CHECK:STDOUT: %T => constants.%T
// CHECK:STDOUT: %Z.type.loc11_11 => constants.%Z.type.c5f
// CHECK:STDOUT: %Self => constants.%Self.dd6
// CHECK:STDOUT: %Self.as_type.loc11_11.2 => constants.%Self.as_type.709
// CHECK:STDOUT: }
// CHECK:STDOUT: