mirror of
https://github.com/carbon-language/carbon-lang.git
synced 2026-10-06 07:34:45 +01:00
Fix handling of member types of generic classes. (#5332)
Instead of evaluating a non-parameterized class or interface to a constant with `SpecificId::None`, use the self specific for that class or interface, which will not be `None` if there is an enclosing generic.
This commit is contained in:
+21
-22
@@ -201,8 +201,7 @@ fn Interface.C.F[self: Self](U:! type, u: U) -> U { return u; }
|
||||
// CHECK:STDOUT: constants {
|
||||
// CHECK:STDOUT: %Interface.type: type = facet_type <@Interface> [concrete]
|
||||
// CHECK:STDOUT: %Self: %Interface.type = bind_symbolic_name Self, 0 [symbolic]
|
||||
// CHECK:STDOUT: %C.1ea: type = class_type @C [concrete]
|
||||
// CHECK:STDOUT: %C.7e5: type = class_type @C, @C(%Self) [symbolic]
|
||||
// CHECK:STDOUT: %C: type = class_type @C, @C(%Self) [symbolic]
|
||||
// CHECK:STDOUT: %U: type = bind_symbolic_name U, 1 [symbolic]
|
||||
// CHECK:STDOUT: %U.patt: type = symbolic_binding_pattern U, 1 [symbolic]
|
||||
// CHECK:STDOUT: %F.type: type = fn_type @F, @C(%Self) [symbolic]
|
||||
@@ -210,7 +209,7 @@ fn Interface.C.F[self: Self](U:! type, u: U) -> U { return u; }
|
||||
// CHECK:STDOUT: %empty_struct_type: type = struct_type {} [concrete]
|
||||
// CHECK:STDOUT: %complete_type: <witness> = complete_type_witness %empty_struct_type [concrete]
|
||||
// CHECK:STDOUT: %require_complete.b54: <witness> = require_complete_type %U [symbolic]
|
||||
// CHECK:STDOUT: %require_complete.e44: <witness> = require_complete_type %C.7e5 [symbolic]
|
||||
// CHECK:STDOUT: %require_complete.e44: <witness> = require_complete_type %C [symbolic]
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: imports {
|
||||
@@ -228,8 +227,8 @@ fn Interface.C.F[self: Self](U:! type, u: U) -> U { return u; }
|
||||
// CHECK:STDOUT: %Core.import = import Core
|
||||
// CHECK:STDOUT: %Interface.decl: type = interface_decl @Interface [concrete = constants.%Interface.type] {} {}
|
||||
// CHECK:STDOUT: %F.decl: @C.%F.type (%F.type) = fn_decl @F [symbolic = constants.%F] {
|
||||
// CHECK:STDOUT: %self.patt: @F.%C (%C.7e5) = binding_pattern self
|
||||
// CHECK:STDOUT: %self.param_patt: @F.%C (%C.7e5) = value_param_pattern %self.patt, call_param0
|
||||
// CHECK:STDOUT: %self.patt: @F.%C (%C) = binding_pattern self
|
||||
// CHECK:STDOUT: %self.param_patt: @F.%C (%C) = value_param_pattern %self.patt, call_param0
|
||||
// CHECK:STDOUT: %U.patt.loc20: type = symbolic_binding_pattern U, 1 [symbolic = %U.patt.loc14 (constants.%U.patt)]
|
||||
// CHECK:STDOUT: %u.patt: @F.%U.loc14_22.1 (%U) = binding_pattern u
|
||||
// CHECK:STDOUT: %u.param_patt: @F.%U.loc14_22.1 (%U) = value_param_pattern %u.patt, call_param1
|
||||
@@ -237,12 +236,12 @@ fn Interface.C.F[self: Self](U:! type, u: U) -> U { return u; }
|
||||
// CHECK:STDOUT: %return.param_patt: @F.%U.loc14_22.1 (%U) = out_param_pattern %return.patt, call_param2
|
||||
// CHECK:STDOUT: } {
|
||||
// CHECK:STDOUT: %U.ref.loc20_49: type = name_ref U, %U.loc20 [symbolic = %U.loc14_22.1 (constants.%U)]
|
||||
// CHECK:STDOUT: %self.param.loc20: @F.%C (%C.7e5) = value_param call_param0
|
||||
// CHECK:STDOUT: %.loc20_24.1: type = splice_block %Self.ref.loc20 [symbolic = %C (constants.%C.7e5)] {
|
||||
// CHECK:STDOUT: %.loc20_24.2: type = specific_constant constants.%C.7e5, @C(constants.%Self) [symbolic = %C (constants.%C.7e5)]
|
||||
// CHECK:STDOUT: %Self.ref.loc20: type = name_ref Self, %.loc20_24.2 [symbolic = %C (constants.%C.7e5)]
|
||||
// CHECK:STDOUT: %self.param.loc20: @F.%C (%C) = value_param call_param0
|
||||
// CHECK:STDOUT: %.loc20_24.1: type = splice_block %Self.ref.loc20 [symbolic = %C (constants.%C)] {
|
||||
// CHECK:STDOUT: %.loc20_24.2: type = specific_constant constants.%C, @C(constants.%Self) [symbolic = %C (constants.%C)]
|
||||
// CHECK:STDOUT: %Self.ref.loc20: type = name_ref Self, %.loc20_24.2 [symbolic = %C (constants.%C)]
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %self.loc20: @F.%C (%C.7e5) = bind_name self, %self.param.loc20
|
||||
// CHECK:STDOUT: %self.loc20: @F.%C (%C) = bind_name self, %self.param.loc20
|
||||
// CHECK:STDOUT: %U.loc20: type = bind_symbolic_name U, 1 [symbolic = %U.loc14_22.1 (constants.%U)]
|
||||
// CHECK:STDOUT: %u.param.loc20: @F.%U.loc14_22.1 (%U) = value_param call_param1
|
||||
// CHECK:STDOUT: %U.ref.loc20_43: type = name_ref U, %U.loc20 [symbolic = %U.loc14_22.1 (constants.%U)]
|
||||
@@ -254,7 +253,7 @@ fn Interface.C.F[self: Self](U:! type, u: U) -> U { return u; }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: interface @Interface {
|
||||
// CHECK:STDOUT: %Self: %Interface.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self]
|
||||
// CHECK:STDOUT: %C.decl: type = class_decl @C [concrete = constants.%C.1ea] {} {}
|
||||
// CHECK:STDOUT: %C.decl: type = class_decl @C [symbolic = constants.%C] {} {}
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !members:
|
||||
// CHECK:STDOUT: .Self = %Self
|
||||
@@ -270,8 +269,8 @@ fn Interface.C.F[self: Self](U:! type, u: U) -> U { return u; }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: class {
|
||||
// CHECK:STDOUT: %F.decl: @C.%F.type (%F.type) = fn_decl @F [symbolic = @C.%F (constants.%F)] {
|
||||
// CHECK:STDOUT: %self.patt: @F.%C (%C.7e5) = binding_pattern self
|
||||
// CHECK:STDOUT: %self.param_patt: @F.%C (%C.7e5) = value_param_pattern %self.patt, call_param0
|
||||
// CHECK:STDOUT: %self.patt: @F.%C (%C) = binding_pattern self
|
||||
// CHECK:STDOUT: %self.param_patt: @F.%C (%C) = value_param_pattern %self.patt, call_param0
|
||||
// CHECK:STDOUT: %U.patt.loc20: type = symbolic_binding_pattern U, 1 [symbolic = %U.patt.loc14 (constants.%U.patt)]
|
||||
// CHECK:STDOUT: %u.patt: @F.%U.loc14_22.1 (%U) = binding_pattern u
|
||||
// CHECK:STDOUT: %u.param_patt: @F.%U.loc14_22.1 (%U) = value_param_pattern %u.patt, call_param1
|
||||
@@ -279,12 +278,12 @@ fn Interface.C.F[self: Self](U:! type, u: U) -> U { return u; }
|
||||
// CHECK:STDOUT: %return.param_patt: @F.%U.loc14_22.1 (%U) = out_param_pattern %return.patt, call_param2
|
||||
// CHECK:STDOUT: } {
|
||||
// CHECK:STDOUT: %U.ref.loc14_41: type = name_ref U, %U.loc14_22.2 [symbolic = %U.loc14_22.1 (constants.%U)]
|
||||
// CHECK:STDOUT: %self.param.loc14: @F.%C (%C.7e5) = value_param call_param0
|
||||
// CHECK:STDOUT: %.loc14_16.1: type = splice_block %Self.ref.loc14 [symbolic = %C (constants.%C.7e5)] {
|
||||
// CHECK:STDOUT: %.loc14_16.2: type = specific_constant constants.%C.7e5, @C(constants.%Self) [symbolic = %C (constants.%C.7e5)]
|
||||
// CHECK:STDOUT: %Self.ref.loc14: type = name_ref Self, %.loc14_16.2 [symbolic = %C (constants.%C.7e5)]
|
||||
// CHECK:STDOUT: %self.param.loc14: @F.%C (%C) = value_param call_param0
|
||||
// CHECK:STDOUT: %.loc14_16.1: type = splice_block %Self.ref.loc14 [symbolic = %C (constants.%C)] {
|
||||
// CHECK:STDOUT: %.loc14_16.2: type = specific_constant constants.%C, @C(constants.%Self) [symbolic = %C (constants.%C)]
|
||||
// CHECK:STDOUT: %Self.ref.loc14: type = name_ref Self, %.loc14_16.2 [symbolic = %C (constants.%C)]
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %self.loc14: @F.%C (%C.7e5) = bind_name self, %self.param.loc14
|
||||
// CHECK:STDOUT: %self.loc14: @F.%C (%C) = bind_name self, %self.param.loc14
|
||||
// CHECK:STDOUT: %U.loc14_22.2: type = bind_symbolic_name U, 1 [symbolic = %U.loc14_22.1 (constants.%U)]
|
||||
// CHECK:STDOUT: %u.param.loc14: @F.%U.loc14_22.1 (%U) = value_param call_param1
|
||||
// CHECK:STDOUT: %U.ref.loc14_35: type = name_ref U, %U.loc14_22.2 [symbolic = %U.loc14_22.1 (constants.%U)]
|
||||
@@ -297,14 +296,14 @@ fn Interface.C.F[self: Self](U:! type, u: U) -> U { return u; }
|
||||
// CHECK:STDOUT: complete_type_witness = %complete_type
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !members:
|
||||
// CHECK:STDOUT: .Self = constants.%C.7e5
|
||||
// CHECK:STDOUT: .Self = constants.%C
|
||||
// CHECK:STDOUT: .F = %F.decl
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: generic fn @F(@Interface.%Self: %Interface.type, %U.loc14_22.2: type) {
|
||||
// CHECK:STDOUT: %Self: %Interface.type = bind_symbolic_name Self, 0 [symbolic = %Self (constants.%Self)]
|
||||
// CHECK:STDOUT: %C: type = class_type @C, @C(%Self) [symbolic = %C (constants.%C.7e5)]
|
||||
// CHECK:STDOUT: %C: type = class_type @C, @C(%Self) [symbolic = %C (constants.%C)]
|
||||
// CHECK:STDOUT: %U.loc14_22.1: type = bind_symbolic_name U, 1 [symbolic = %U.loc14_22.1 (constants.%U)]
|
||||
// CHECK:STDOUT: %U.patt.loc14: type = symbolic_binding_pattern U, 1 [symbolic = %U.patt.loc14 (constants.%U.patt)]
|
||||
// CHECK:STDOUT:
|
||||
@@ -312,7 +311,7 @@ fn Interface.C.F[self: Self](U:! type, u: U) -> U { return u; }
|
||||
// CHECK:STDOUT: %require_complete.loc20_46: <witness> = require_complete_type %U.loc14_22.1 [symbolic = %require_complete.loc20_46 (constants.%require_complete.b54)]
|
||||
// CHECK:STDOUT: %require_complete.loc20_22: <witness> = require_complete_type %C [symbolic = %require_complete.loc20_22 (constants.%require_complete.e44)]
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn[%self.param_patt: @F.%C (%C.7e5)](%U.patt.loc20: type, %u.param_patt: @F.%U.loc14_22.1 (%U)) -> @F.%U.loc14_22.1 (%U) {
|
||||
// CHECK:STDOUT: fn[%self.param_patt: @F.%C (%C)](%U.patt.loc20: type, %u.param_patt: @F.%U.loc14_22.1 (%U)) -> @F.%U.loc14_22.1 (%U) {
|
||||
// CHECK:STDOUT: !entry:
|
||||
// CHECK:STDOUT: %u.ref: @F.%U.loc14_22.1 (%U) = name_ref u, %u.loc20
|
||||
// CHECK:STDOUT: return %u.ref
|
||||
@@ -328,7 +327,7 @@ fn Interface.C.F[self: Self](U:! type, u: U) -> U { return u; }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: specific @F(constants.%Self, constants.%U) {
|
||||
// CHECK:STDOUT: %Self => constants.%Self
|
||||
// CHECK:STDOUT: %C => constants.%C.7e5
|
||||
// CHECK:STDOUT: %C => constants.%C
|
||||
// CHECK:STDOUT: %U.loc14_22.1 => constants.%U
|
||||
// CHECK:STDOUT: %U.patt.loc14 => constants.%U.patt
|
||||
// CHECK:STDOUT: }
|
||||
|
||||
+9
-10
@@ -41,9 +41,8 @@ interface Outer {
|
||||
// CHECK:STDOUT: %F.5d3: %F.type.1ad = struct_value () [concrete]
|
||||
// CHECK:STDOUT: %Outer.type: type = facet_type <@Outer> [concrete]
|
||||
// CHECK:STDOUT: %Self.277: %Outer.type = bind_symbolic_name Self, 0 [symbolic]
|
||||
// CHECK:STDOUT: %Inner.type.428: type = facet_type <@Inner> [concrete]
|
||||
// CHECK:STDOUT: %Inner.type.3d8: type = facet_type <@Inner, @Inner(%Self.277)> [symbolic]
|
||||
// CHECK:STDOUT: %Self.b60: %Inner.type.3d8 = bind_symbolic_name Self, 1 [symbolic]
|
||||
// CHECK:STDOUT: %Inner.type: type = facet_type <@Inner, @Inner(%Self.277)> [symbolic]
|
||||
// CHECK:STDOUT: %Self.b60: %Inner.type = bind_symbolic_name Self, 1 [symbolic]
|
||||
// CHECK:STDOUT: %F.type.82c77c.1: type = fn_type @F.2, @Inner(%Self.277) [symbolic]
|
||||
// CHECK:STDOUT: %F.9789e2.1: %F.type.82c77c.1 = struct_value () [symbolic]
|
||||
// CHECK:STDOUT: %F.type.82c77c.2: type = fn_type @F.3, @Inner(%Self.277) [symbolic]
|
||||
@@ -71,7 +70,7 @@ interface Outer {
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: interface @Outer {
|
||||
// CHECK:STDOUT: %Self: %Outer.type = bind_symbolic_name Self, 0 [symbolic = constants.%Self.277]
|
||||
// CHECK:STDOUT: %Inner.decl: type = interface_decl @Inner [concrete = constants.%Inner.type.428] {} {}
|
||||
// CHECK:STDOUT: %Inner.decl: type = interface_decl @Inner [symbolic = constants.%Inner.type] {} {}
|
||||
// CHECK:STDOUT: %F.decl: %F.type.82c77c.2 = fn_decl @F.3 [symbolic = constants.%F.9789e2.2] {} {}
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !members:
|
||||
@@ -83,13 +82,13 @@ interface Outer {
|
||||
// CHECK:STDOUT: generic interface @Inner(@Outer.%Self: %Outer.type) {
|
||||
// CHECK:STDOUT: !definition:
|
||||
// CHECK:STDOUT: %Self.2: %Outer.type = bind_symbolic_name Self, 0 [symbolic = %Self.2 (constants.%Self.277)]
|
||||
// CHECK:STDOUT: %Inner.type: type = facet_type <@Inner, @Inner(%Self.2)> [symbolic = %Inner.type (constants.%Inner.type.3d8)]
|
||||
// CHECK:STDOUT: %Self.3: @Inner.%Inner.type (%Inner.type.3d8) = bind_symbolic_name Self, 1 [symbolic = %Self.3 (constants.%Self.b60)]
|
||||
// CHECK:STDOUT: %Inner.type: type = facet_type <@Inner, @Inner(%Self.2)> [symbolic = %Inner.type (constants.%Inner.type)]
|
||||
// CHECK:STDOUT: %Self.3: @Inner.%Inner.type (%Inner.type) = bind_symbolic_name Self, 1 [symbolic = %Self.3 (constants.%Self.b60)]
|
||||
// CHECK:STDOUT: %F.type: type = fn_type @F.2, @Inner(%Self.2) [symbolic = %F.type (constants.%F.type.82c77c.1)]
|
||||
// CHECK:STDOUT: %F: @Inner.%F.type (%F.type.82c77c.1) = struct_value () [symbolic = %F (constants.%F.9789e2.1)]
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: interface {
|
||||
// CHECK:STDOUT: %Self.1: @Inner.%Inner.type (%Inner.type.3d8) = bind_symbolic_name Self, 1 [symbolic = %Self.3 (constants.%Self.b60)]
|
||||
// CHECK:STDOUT: %Self.1: @Inner.%Inner.type (%Inner.type) = bind_symbolic_name Self, 1 [symbolic = %Self.3 (constants.%Self.b60)]
|
||||
// CHECK:STDOUT: %F.decl: @Inner.%F.type (%F.type.82c77c.1) = fn_decl @F.2 [symbolic = @Inner.%F (constants.%F.9789e2.1)] {} {}
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !members:
|
||||
@@ -108,11 +107,11 @@ interface Outer {
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: generic fn @F.2(@Outer.%Self: %Outer.type, @Inner.%Self.1: @Inner.%Inner.type (%Inner.type.3d8)) {
|
||||
// CHECK:STDOUT: generic fn @F.2(@Outer.%Self: %Outer.type, @Inner.%Self.1: @Inner.%Inner.type (%Inner.type)) {
|
||||
// CHECK:STDOUT: fn();
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: generic fn @F.3(@Outer.%Self: %Outer.type, @Inner.%Self.1: @Inner.%Inner.type (%Inner.type.3d8)) {
|
||||
// CHECK:STDOUT: generic fn @F.3(@Outer.%Self: %Outer.type, @Inner.%Self.1: @Inner.%Inner.type (%Inner.type)) {
|
||||
// CHECK:STDOUT: fn();
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -121,7 +120,7 @@ interface Outer {
|
||||
// CHECK:STDOUT: specific @Inner(constants.%Self.277) {
|
||||
// CHECK:STDOUT: !definition:
|
||||
// CHECK:STDOUT: %Self.2 => constants.%Self.277
|
||||
// CHECK:STDOUT: %Inner.type => constants.%Inner.type.3d8
|
||||
// CHECK:STDOUT: %Inner.type => constants.%Inner.type
|
||||
// CHECK:STDOUT: %Self.3 => constants.%Self.b60
|
||||
// CHECK:STDOUT: %F.type => constants.%F.type.82c77c.1
|
||||
// CHECK:STDOUT: %F => constants.%F.9789e2.1
|
||||
|
||||
@@ -86,7 +86,6 @@ interface Bar[T:! type] {}
|
||||
// CHECK:STDOUT: %C.type: type = generic_class_type @C [concrete]
|
||||
// CHECK:STDOUT: %C.generic: %C.type = struct_value () [concrete]
|
||||
// CHECK:STDOUT: %C.f2e: type = class_type @C, @C(%T) [symbolic]
|
||||
// CHECK:STDOUT: %GenericNoParams.type.f90: type = facet_type <@GenericNoParams> [concrete]
|
||||
// CHECK:STDOUT: %GenericNoParams.type.b79: type = facet_type <@GenericNoParams, @GenericNoParams(%T)> [symbolic]
|
||||
// CHECK:STDOUT: %Self.0f6: %GenericNoParams.type.b79 = bind_symbolic_name Self, 1 [symbolic]
|
||||
// CHECK:STDOUT: %U: type = bind_symbolic_name U, 1 [symbolic]
|
||||
@@ -104,8 +103,10 @@ interface Bar[T:! type] {}
|
||||
// CHECK:STDOUT: %Self.2f7: %GenericAndParams.type.4b6 = bind_symbolic_name Self, 1 [symbolic]
|
||||
// CHECK:STDOUT: %GenericAndParams.impl_witness.c06: <witness> = impl_witness file.%GenericAndParams.impl_witness_table.loc16 [concrete]
|
||||
// CHECK:STDOUT: %C.fac: type = class_type @C, @C(%X) [concrete]
|
||||
// CHECK:STDOUT: %GenericNoParams.type.b7e: type = facet_type <@GenericNoParams, @GenericNoParams(%X)> [concrete]
|
||||
// CHECK:STDOUT: %GenericAndParams.type.425: type = generic_interface_type @GenericAndParams.2, @C(%X) [concrete]
|
||||
// CHECK:STDOUT: %GenericAndParams.generic.b50: %GenericAndParams.type.425 = struct_value () [concrete]
|
||||
// CHECK:STDOUT: %Self.108: %GenericNoParams.type.b7e = bind_symbolic_name Self, 1 [symbolic]
|
||||
// CHECK:STDOUT: %GenericNoParams.impl_witness: <witness> = impl_witness file.%GenericNoParams.impl_witness_table [concrete]
|
||||
// CHECK:STDOUT: %GenericAndParams.type.79c: type = facet_type <@GenericAndParams.2, @GenericAndParams.2(%X, %X)> [concrete]
|
||||
// CHECK:STDOUT: %Self.f51: %GenericAndParams.type.79c = bind_symbolic_name Self, 2 [symbolic]
|
||||
@@ -154,14 +155,15 @@ interface Bar[T:! type] {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %GenericAndParams.impl_witness_table.loc16 = impl_witness_table (), @impl.87f [concrete]
|
||||
// CHECK:STDOUT: %GenericAndParams.impl_witness.loc16: <witness> = impl_witness %GenericAndParams.impl_witness_table.loc16 [concrete = constants.%GenericAndParams.impl_witness.c06]
|
||||
// CHECK:STDOUT: impl_decl @impl.3f8 [concrete] {} {
|
||||
// CHECK:STDOUT: impl_decl @impl.cd5 [concrete] {} {
|
||||
// CHECK:STDOUT: %X.ref.loc17_6: type = name_ref X, file.%X.decl [concrete = constants.%X]
|
||||
// CHECK:STDOUT: %C.ref: %C.type = name_ref C, file.%C.decl [concrete = constants.%C.generic]
|
||||
// CHECK:STDOUT: %X.ref.loc17_13: type = name_ref X, file.%X.decl [concrete = constants.%X]
|
||||
// CHECK:STDOUT: %C: type = class_type @C, @C(constants.%X) [concrete = constants.%C.fac]
|
||||
// CHECK:STDOUT: %GenericNoParams.ref: type = name_ref GenericNoParams, @C.%GenericNoParams.decl [concrete = constants.%GenericNoParams.type.f90]
|
||||
// CHECK:STDOUT: %.loc17: type = specific_constant @C.%GenericNoParams.decl, @C(constants.%X) [concrete = constants.%GenericNoParams.type.b7e]
|
||||
// CHECK:STDOUT: %GenericNoParams.ref: type = name_ref GenericNoParams, %.loc17 [concrete = constants.%GenericNoParams.type.b7e]
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %GenericNoParams.impl_witness_table = impl_witness_table (), @impl.3f8 [concrete]
|
||||
// CHECK:STDOUT: %GenericNoParams.impl_witness_table = impl_witness_table (), @impl.cd5 [concrete]
|
||||
// CHECK:STDOUT: %GenericNoParams.impl_witness: <witness> = impl_witness %GenericNoParams.impl_witness_table [concrete = constants.%GenericNoParams.impl_witness]
|
||||
// CHECK:STDOUT: impl_decl @impl.15f [concrete] {} {
|
||||
// CHECK:STDOUT: %X.ref.loc18_6: type = name_ref X, file.%X.decl [concrete = constants.%X]
|
||||
@@ -258,7 +260,7 @@ interface Bar[T:! type] {}
|
||||
// CHECK:STDOUT: witness = file.%GenericAndParams.impl_witness.loc16
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: impl @impl.3f8: %X.ref.loc17_6 as %GenericNoParams.ref {
|
||||
// CHECK:STDOUT: impl @impl.cd5: %X.ref.loc17_6 as %GenericNoParams.ref {
|
||||
// CHECK:STDOUT: !members:
|
||||
// CHECK:STDOUT: witness = file.%GenericNoParams.impl_witness
|
||||
// CHECK:STDOUT: }
|
||||
@@ -273,11 +275,12 @@ interface Bar[T:! type] {}
|
||||
// CHECK:STDOUT: %T.patt.loc8_9.2: type = symbolic_binding_pattern T, 0 [symbolic = %T.patt.loc8_9.2 (constants.%T.patt)]
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !definition:
|
||||
// CHECK:STDOUT: %GenericNoParams.type: type = facet_type <@GenericNoParams, @GenericNoParams(%T.loc8_9.2)> [symbolic = %GenericNoParams.type (constants.%GenericNoParams.type.b79)]
|
||||
// CHECK:STDOUT: %GenericAndParams.type: type = generic_interface_type @GenericAndParams.2, @C(%T.loc8_9.2) [symbolic = %GenericAndParams.type (constants.%GenericAndParams.type.597)]
|
||||
// CHECK:STDOUT: %GenericAndParams.generic: @C.%GenericAndParams.type (%GenericAndParams.type.597) = struct_value () [symbolic = %GenericAndParams.generic (constants.%GenericAndParams.generic.2ec)]
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: class {
|
||||
// CHECK:STDOUT: %GenericNoParams.decl: type = interface_decl @GenericNoParams [concrete = constants.%GenericNoParams.type.f90] {} {}
|
||||
// CHECK:STDOUT: %GenericNoParams.decl: type = interface_decl @GenericNoParams [symbolic = @C.%GenericNoParams.type (constants.%GenericNoParams.type.b79)] {} {}
|
||||
// CHECK:STDOUT: %GenericAndParams.decl: @C.%GenericAndParams.type (%GenericAndParams.type.597) = interface_decl @GenericAndParams.2 [symbolic = @C.%GenericAndParams.generic (constants.%GenericAndParams.generic.2ec)] {
|
||||
// CHECK:STDOUT: %U.patt.loc10_30.1: type = symbolic_binding_pattern U, 1 [symbolic = %U.patt.loc10_30.2 (constants.%U.patt)]
|
||||
// CHECK:STDOUT: } {
|
||||
@@ -326,6 +329,8 @@ interface Bar[T:! type] {}
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: specific @GenericAndParams.2(%T, %U.loc10_30.2) {}
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: specific @GenericNoParams(@C.%T.loc8_9.2) {}
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: specific @C(%T.loc8_9.2) {}
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: specific @GenericAndParams.1(constants.%X) {
|
||||
@@ -342,10 +347,18 @@ interface Bar[T:! type] {}
|
||||
// CHECK:STDOUT: %T.patt.loc8_9.2 => constants.%T.patt
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: !definition:
|
||||
// CHECK:STDOUT: %GenericNoParams.type => constants.%GenericNoParams.type.b7e
|
||||
// CHECK:STDOUT: %GenericAndParams.type => constants.%GenericAndParams.type.425
|
||||
// CHECK:STDOUT: %GenericAndParams.generic => constants.%GenericAndParams.generic.b50
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: specific @GenericNoParams(constants.%X) {
|
||||
// CHECK:STDOUT: !definition:
|
||||
// CHECK:STDOUT: %T => constants.%X
|
||||
// CHECK:STDOUT: %GenericNoParams.type => constants.%GenericNoParams.type.b7e
|
||||
// CHECK:STDOUT: %Self.2 => constants.%Self.108
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: specific @GenericAndParams.2(constants.%X, constants.%X) {
|
||||
// CHECK:STDOUT: %U.loc10_30.2 => constants.%X
|
||||
// CHECK:STDOUT: %U.patt.loc10_30.2 => constants.%U.patt
|
||||
|
||||
Reference in New Issue
Block a user