mirror of
https://github.com/carbon-language/carbon-lang.git
synced 2026-10-05 22:02:55 +01:00
Give ReturnExpr a target only when initialization is in-place (#6570)
Also clarify and enforce that `ConversionTarget::init_id` is used only as storage for in-place initialization, and correspondingly rename it to `storage_id`.
This commit is contained in:
+1
-1
@@ -196,6 +196,6 @@ fn RuntimeCall(a: i32, b: i32) -> i32 {
|
||||
// CHECK:STDOUT: %a.ref: %i32 = name_ref a, %a
|
||||
// CHECK:STDOUT: %b.ref: %i32 = name_ref b, %b
|
||||
// CHECK:STDOUT: %Add.call: init %i32 = call %Add.ref(%a.ref, %b.ref)
|
||||
// CHECK:STDOUT: return %Add.call to %return.param
|
||||
// CHECK:STDOUT: return %Add.call
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
|
||||
@@ -265,7 +265,7 @@ fn C(n: i32, m: i32) -> i32 = "int.sadd";
|
||||
// CHECK:STDOUT: %specific_fn: <specific function> = specific_function %impl.elem0, @Int.as.Copy.impl.Op(constants.%int_32) [concrete = constants.%Int.as.Copy.impl.Op.specific_fn]
|
||||
// CHECK:STDOUT: %bound_method.loc23_38.2: <bound method> = bound_method %n.ref, %specific_fn
|
||||
// CHECK:STDOUT: %Int.as.Copy.impl.Op.call: init %i32 = call %bound_method.loc23_38.2(%n.ref)
|
||||
// CHECK:STDOUT: return %Int.as.Copy.impl.Op.call to %return.param
|
||||
// CHECK:STDOUT: return %Int.as.Copy.impl.Op.call
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @B.loc25(%n.param: %i32, %m.param: %i32) -> %i32 {
|
||||
@@ -276,7 +276,7 @@ fn C(n: i32, m: i32) -> i32 = "int.sadd";
|
||||
// CHECK:STDOUT: %specific_fn: <specific function> = specific_function %impl.elem0, @Int.as.Copy.impl.Op(constants.%int_32) [concrete = constants.%Int.as.Copy.impl.Op.specific_fn]
|
||||
// CHECK:STDOUT: %bound_method.loc25_38.2: <bound method> = bound_method %n.ref, %specific_fn
|
||||
// CHECK:STDOUT: %Int.as.Copy.impl.Op.call: init %i32 = call %bound_method.loc25_38.2(%n.ref)
|
||||
// CHECK:STDOUT: return %Int.as.Copy.impl.Op.call to %return.param
|
||||
// CHECK:STDOUT: return %Int.as.Copy.impl.Op.call
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @B.loc33(%n.param: %i32, %m.param: %i32) -> %i32 = "int.sadd";
|
||||
|
||||
+2
-2
@@ -71,9 +71,9 @@ fn Main() {
|
||||
// CHECK:STDOUT: fn @A() -> %empty_tuple.type {
|
||||
// CHECK:STDOUT: !entry:
|
||||
// CHECK:STDOUT: %.loc15_24.1: %empty_tuple.type = tuple_literal () [concrete = constants.%empty_tuple]
|
||||
// CHECK:STDOUT: %.loc15_24.2: init %empty_tuple.type = tuple_init () to %return.param [concrete = constants.%empty_tuple]
|
||||
// CHECK:STDOUT: %.loc15_24.2: init %empty_tuple.type = tuple_init () [concrete = constants.%empty_tuple]
|
||||
// CHECK:STDOUT: %.loc15_25: init %empty_tuple.type = converted %.loc15_24.1, %.loc15_24.2 [concrete = constants.%empty_tuple]
|
||||
// CHECK:STDOUT: return %.loc15_25 to %return.param
|
||||
// CHECK:STDOUT: return %.loc15_25
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @Main() {
|
||||
|
||||
@@ -62,9 +62,9 @@ fn Main() {
|
||||
// CHECK:STDOUT: fn @Echo(%a.param: %empty_struct_type) -> %empty_struct_type {
|
||||
// CHECK:STDOUT: !entry:
|
||||
// CHECK:STDOUT: %a.ref: %empty_struct_type = name_ref a, %a
|
||||
// CHECK:STDOUT: %.loc16_10: init %empty_struct_type = struct_init () to %return.param [concrete = constants.%empty_struct]
|
||||
// CHECK:STDOUT: %.loc16_10: init %empty_struct_type = struct_init () [concrete = constants.%empty_struct]
|
||||
// CHECK:STDOUT: %.loc16_11: init %empty_struct_type = converted %a.ref, %.loc16_10 [concrete = constants.%empty_struct]
|
||||
// CHECK:STDOUT: return %.loc16_11 to %return.param
|
||||
// CHECK:STDOUT: return %.loc16_11
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @Main() {
|
||||
|
||||
@@ -62,9 +62,9 @@ fn Main() {
|
||||
// CHECK:STDOUT: fn @Echo(%a.param: %empty_tuple.type) -> %empty_tuple.type {
|
||||
// CHECK:STDOUT: !entry:
|
||||
// CHECK:STDOUT: %a.ref: %empty_tuple.type = name_ref a, %a
|
||||
// CHECK:STDOUT: %.loc16_10: init %empty_tuple.type = tuple_init () to %return.param [concrete = constants.%empty_tuple]
|
||||
// CHECK:STDOUT: %.loc16_10: init %empty_tuple.type = tuple_init () [concrete = constants.%empty_tuple]
|
||||
// CHECK:STDOUT: %.loc16_11: init %empty_tuple.type = converted %a.ref, %.loc16_10 [concrete = constants.%empty_tuple]
|
||||
// CHECK:STDOUT: return %.loc16_11 to %return.param
|
||||
// CHECK:STDOUT: return %.loc16_11
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @Main() {
|
||||
|
||||
@@ -112,7 +112,7 @@ fn Run() {
|
||||
// CHECK:STDOUT: %bound_method.loc15_29.2: <bound method> = bound_method %float, %specific_fn [concrete = constants.%bound_method]
|
||||
// CHECK:STDOUT: %Core.FloatLiteral.as.ImplicitAs.impl.Convert.call: init %f64.d77 = call %bound_method.loc15_29.2(%float) [concrete = constants.%float.d20]
|
||||
// CHECK:STDOUT: %.loc15_29: init %f64.d77 = converted %float, %Core.FloatLiteral.as.ImplicitAs.impl.Convert.call [concrete = constants.%float.d20]
|
||||
// CHECK:STDOUT: return %.loc15_29 to %return.param
|
||||
// CHECK:STDOUT: return %.loc15_29
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @Run() {
|
||||
|
||||
+1
-1
@@ -122,7 +122,7 @@ fn Main() {
|
||||
// CHECK:STDOUT: %specific_fn: <specific function> = specific_function %impl.elem0, @Int.as.Copy.impl.Op(constants.%int_32) [concrete = constants.%Int.as.Copy.impl.Op.specific_fn]
|
||||
// CHECK:STDOUT: %bound_method.loc16_10.2: <bound method> = bound_method %a.ref, %specific_fn
|
||||
// CHECK:STDOUT: %Int.as.Copy.impl.Op.call: init %i32 = call %bound_method.loc16_10.2(%a.ref)
|
||||
// CHECK:STDOUT: return %Int.as.Copy.impl.Op.call to %return.param
|
||||
// CHECK:STDOUT: return %Int.as.Copy.impl.Op.call
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @Main() {
|
||||
|
||||
@@ -131,7 +131,7 @@ fn Main() {
|
||||
// CHECK:STDOUT: %bound_method.loc18_22.2: <bound method> = bound_method %int_1, %specific_fn.loc18 [concrete = constants.%bound_method.38b]
|
||||
// CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.call.loc18: init %i32 = call %bound_method.loc18_22.2(%int_1) [concrete = constants.%int_1.5d2]
|
||||
// CHECK:STDOUT: %.loc18_22.2: init %i32 = converted %int_1, %Core.IntLiteral.as.ImplicitAs.impl.Convert.call.loc18 [concrete = constants.%int_1.5d2]
|
||||
// CHECK:STDOUT: %.loc18_22.3: init %tuple.type.a1c = tuple_init (%.loc18_22.2) to %x.var [concrete = constants.%tuple.246]
|
||||
// CHECK:STDOUT: %.loc18_22.3: init %tuple.type.a1c = tuple_init (%.loc18_22.2) [concrete = constants.%tuple.246]
|
||||
// CHECK:STDOUT: %.loc18_3: init %tuple.type.a1c = converted %.loc18_22.1, %.loc18_22.3 [concrete = constants.%tuple.246]
|
||||
// CHECK:STDOUT: assign %x.var, %.loc18_3
|
||||
// CHECK:STDOUT: %.loc18_15.1: type = splice_block %.loc18_15.3 [concrete = constants.%tuple.type.a1c] {
|
||||
|
||||
@@ -177,7 +177,7 @@ fn Class(F:! type).Inner.G() -> i32 { return F(); }
|
||||
// CHECK:STDOUT: %bound_method.loc8_29.2: <bound method> = bound_method %int_0, %specific_fn [concrete = constants.%bound_method]
|
||||
// CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.call: init %i32 = call %bound_method.loc8_29.2(%int_0) [concrete = constants.%int_0.6a9]
|
||||
// CHECK:STDOUT: %.loc8_29: init %i32 = converted %int_0, %Core.IntLiteral.as.ImplicitAs.impl.Convert.call [concrete = constants.%int_0.6a9]
|
||||
// CHECK:STDOUT: return %.loc8_29 to %return.param
|
||||
// CHECK:STDOUT: return %.loc8_29
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -194,7 +194,7 @@ fn Class(F:! type).Inner.G() -> i32 { return F(); }
|
||||
// CHECK:STDOUT: %F.ref: @Inner.G.%Inner.F.type (%Inner.F.type) = name_ref F, %.loc13_46 [symbolic = %Inner.F (constants.%Inner.F)]
|
||||
// CHECK:STDOUT: %Inner.F.specific_fn.loc13_46.1: <specific function> = specific_function %F.ref, @Inner.F(constants.%F) [symbolic = %Inner.F.specific_fn.loc13_46.2 (constants.%Inner.F.specific_fn)]
|
||||
// CHECK:STDOUT: %Inner.F.call: init %i32 = call %Inner.F.specific_fn.loc13_46.1()
|
||||
// CHECK:STDOUT: return %Inner.F.call to %return.param.loc13
|
||||
// CHECK:STDOUT: return %Inner.F.call
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
|
||||
+4
-4
@@ -227,9 +227,9 @@ fn K() -> {} { return {}; }
|
||||
// CHECK:STDOUT: fn @I.loc50() -> %empty_tuple.type {
|
||||
// CHECK:STDOUT: !entry:
|
||||
// CHECK:STDOUT: %.loc50_24.1: %empty_tuple.type = tuple_literal () [concrete = constants.%empty_tuple]
|
||||
// CHECK:STDOUT: %.loc50_24.2: init %empty_tuple.type = tuple_init () to %return.param [concrete = constants.%empty_tuple]
|
||||
// CHECK:STDOUT: %.loc50_24.2: init %empty_tuple.type = tuple_init () [concrete = constants.%empty_tuple]
|
||||
// CHECK:STDOUT: %.loc50_25: init %empty_tuple.type = converted %.loc50_24.1, %.loc50_24.2 [concrete = constants.%empty_tuple]
|
||||
// CHECK:STDOUT: return %.loc50_25 to %return.param
|
||||
// CHECK:STDOUT: return %.loc50_25
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @J.loc52() -> %empty_tuple.type;
|
||||
@@ -244,8 +244,8 @@ fn K() -> {} { return {}; }
|
||||
// CHECK:STDOUT: fn @K.loc70() -> %empty_struct_type {
|
||||
// CHECK:STDOUT: !entry:
|
||||
// CHECK:STDOUT: %.loc70_24.1: %empty_struct_type = struct_literal () [concrete = constants.%empty_struct]
|
||||
// CHECK:STDOUT: %.loc70_24.2: init %empty_struct_type = struct_init () to %return.param [concrete = constants.%empty_struct]
|
||||
// CHECK:STDOUT: %.loc70_24.2: init %empty_struct_type = struct_init () [concrete = constants.%empty_struct]
|
||||
// CHECK:STDOUT: %.loc70_25: init %empty_struct_type = converted %.loc70_24.1, %.loc70_24.2 [concrete = constants.%empty_struct]
|
||||
// CHECK:STDOUT: return %.loc70_25 to %return.param
|
||||
// CHECK:STDOUT: return %.loc70_25
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
|
||||
@@ -230,7 +230,7 @@ fn D() {}
|
||||
// CHECK:STDOUT: %specific_fn: <specific function> = specific_function %impl.elem0, @Int.as.Copy.impl.Op(constants.%int_32) [concrete = constants.%Int.as.Copy.impl.Op.specific_fn]
|
||||
// CHECK:STDOUT: %bound_method.loc5_30.2: <bound method> = bound_method %b.ref, %specific_fn
|
||||
// CHECK:STDOUT: %Int.as.Copy.impl.Op.call: init %i32 = call %bound_method.loc5_30.2(%b.ref)
|
||||
// CHECK:STDOUT: return %Int.as.Copy.impl.Op.call to %return.param
|
||||
// CHECK:STDOUT: return %Int.as.Copy.impl.Op.call
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @C(%c.param: %tuple.type.a1c) -> %struct_type.c {
|
||||
@@ -244,9 +244,9 @@ fn D() {}
|
||||
// CHECK:STDOUT: %specific_fn: <specific function> = specific_function %impl.elem0, @Int.as.Copy.impl.Op(constants.%int_32) [concrete = constants.%Int.as.Copy.impl.Op.specific_fn]
|
||||
// CHECK:STDOUT: %bound_method.loc6_46.2: <bound method> = bound_method %tuple.elem0, %specific_fn
|
||||
// CHECK:STDOUT: %Int.as.Copy.impl.Op.call: init %i32 = call %bound_method.loc6_46.2(%tuple.elem0)
|
||||
// CHECK:STDOUT: %.loc6_48.2: init %struct_type.c = struct_init (%Int.as.Copy.impl.Op.call) to %return.param
|
||||
// CHECK:STDOUT: %.loc6_48.2: init %struct_type.c = struct_init (%Int.as.Copy.impl.Op.call)
|
||||
// CHECK:STDOUT: %.loc6_49: init %struct_type.c = converted %.loc6_48.1, %.loc6_48.2
|
||||
// CHECK:STDOUT: return %.loc6_49 to %return.param
|
||||
// CHECK:STDOUT: return %.loc6_49
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @D();
|
||||
|
||||
+4
-4
@@ -228,7 +228,7 @@ fn CallSpecific(x: C*) -> C* {
|
||||
// CHECK:STDOUT: %.loc18_24.3: %Copy.type = converted constants.%ptr.e8f, %Copy.facet.loc18_24.3 [symbolic = %Copy.facet.loc18_24.4 (constants.%Copy.facet.c25)]
|
||||
// CHECK:STDOUT: %Function.specific_fn.loc18_10.1: <specific function> = specific_function %Function.ref, @Function(constants.%Copy.facet.c25) [symbolic = %Function.specific_fn.loc18_10.2 (constants.%Function.specific_fn.919)]
|
||||
// CHECK:STDOUT: %Function.call: init @CallGenericPtr.%ptr.loc16_33.1 (%ptr.e8f) = call %Function.specific_fn.loc18_10.1(%x.ref)
|
||||
// CHECK:STDOUT: return %Function.call to %return.param
|
||||
// CHECK:STDOUT: return %Function.call
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -246,7 +246,7 @@ fn CallSpecific(x: C*) -> C* {
|
||||
// CHECK:STDOUT: %.loc26_24.3: %Copy.type = converted constants.%ptr.31e, %Copy.facet.loc26_24.3 [concrete = constants.%Copy.facet.a7f]
|
||||
// CHECK:STDOUT: %Function.specific_fn: <specific function> = specific_function %Function.ref, @Function(constants.%Copy.facet.a7f) [concrete = constants.%Function.specific_fn.9da]
|
||||
// CHECK:STDOUT: %Function.call: init %ptr.31e = call %Function.specific_fn(%x.ref)
|
||||
// CHECK:STDOUT: return %Function.call to %return.param
|
||||
// CHECK:STDOUT: return %Function.call
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: specific @Function(constants.%T.035) {
|
||||
@@ -458,7 +458,7 @@ fn CallSpecific(x: C*) -> C* {
|
||||
// CHECK:STDOUT: %.loc18_20.2: %Copy.type = converted constants.%ptr.e8f, %Copy.facet.loc18_20.2 [symbolic = %Copy.facet.loc18_20.3 (constants.%Copy.facet.c25)]
|
||||
// CHECK:STDOUT: %Function.specific_fn.loc18_10.1: <specific function> = specific_function %Function.ref, @Function(constants.%Copy.facet.c25) [symbolic = %Function.specific_fn.loc18_10.2 (constants.%Function.specific_fn.919)]
|
||||
// CHECK:STDOUT: %Function.call: init @CallGenericPtr.%ptr.loc16_33.1 (%ptr.e8f) = call %Function.specific_fn.loc18_10.1(%x.ref)
|
||||
// CHECK:STDOUT: return %Function.call to %return.param
|
||||
// CHECK:STDOUT: return %Function.call
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -472,7 +472,7 @@ fn CallSpecific(x: C*) -> C* {
|
||||
// CHECK:STDOUT: %.loc26_20.2: %Copy.type = converted constants.%ptr.31e, %Copy.facet.loc26_20.2 [concrete = constants.%Copy.facet.a7f]
|
||||
// CHECK:STDOUT: %Function.specific_fn: <specific function> = specific_function %Function.ref, @Function(constants.%Copy.facet.a7f) [concrete = constants.%Function.specific_fn.9da]
|
||||
// CHECK:STDOUT: %Function.call: init %ptr.31e = call %Function.specific_fn(%x.ref)
|
||||
// CHECK:STDOUT: return %Function.call to %return.param
|
||||
// CHECK:STDOUT: return %Function.call
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: specific @Function(constants.%T.035) {
|
||||
|
||||
+8
-8
@@ -321,7 +321,7 @@ fn F() {
|
||||
// CHECK:STDOUT: %T.ref.loc4_71: type = name_ref T, %T.loc4_25.2 [symbolic = %T.loc4_25.1 (constants.%T)]
|
||||
// CHECK:STDOUT: %ExplicitGenericParam.specific_fn.loc4_50.1: <specific function> = specific_function %ExplicitGenericParam.ref, @ExplicitGenericParam(constants.%T) [symbolic = %ExplicitGenericParam.specific_fn.loc4_50.2 (constants.%ExplicitGenericParam.specific_fn.409)]
|
||||
// CHECK:STDOUT: %ExplicitGenericParam.call: init @ExplicitGenericParam.%ptr.loc4_39.1 (%ptr.e8f) = call %ExplicitGenericParam.specific_fn.loc4_50.1()
|
||||
// CHECK:STDOUT: return %ExplicitGenericParam.call to %return.param
|
||||
// CHECK:STDOUT: return %ExplicitGenericParam.call
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -332,7 +332,7 @@ fn F() {
|
||||
// CHECK:STDOUT: %i32.loc7: type = class_type @Int, @Int(constants.%int_32) [concrete = constants.%i32]
|
||||
// CHECK:STDOUT: %ExplicitGenericParam.specific_fn: <specific function> = specific_function %ExplicitGenericParam.ref, @ExplicitGenericParam(constants.%i32) [concrete = constants.%ExplicitGenericParam.specific_fn.3d2]
|
||||
// CHECK:STDOUT: %ExplicitGenericParam.call: init %ptr.235 = call %ExplicitGenericParam.specific_fn()
|
||||
// CHECK:STDOUT: return %ExplicitGenericParam.call to %return.param
|
||||
// CHECK:STDOUT: return %ExplicitGenericParam.call
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: generic fn @CallExplicitGenericParamWithGenericArg(%T.loc10_43.2: type) {
|
||||
@@ -353,7 +353,7 @@ fn F() {
|
||||
// CHECK:STDOUT: %struct_type.a.loc11: type = struct_type {.a: @CallExplicitGenericParamWithGenericArg.%T.loc10_43.1 (%T)} [symbolic = %struct_type.a.loc10_62.1 (constants.%struct_type.a)]
|
||||
// CHECK:STDOUT: %ExplicitGenericParam.specific_fn.loc11_10.1: <specific function> = specific_function %ExplicitGenericParam.ref, @ExplicitGenericParam(constants.%struct_type.a) [symbolic = %ExplicitGenericParam.specific_fn.loc11_10.2 (constants.%ExplicitGenericParam.specific_fn.55c)]
|
||||
// CHECK:STDOUT: %ExplicitGenericParam.call: init @CallExplicitGenericParamWithGenericArg.%ptr.loc10_63.1 (%ptr.88d) = call %ExplicitGenericParam.specific_fn.loc11_10.1()
|
||||
// CHECK:STDOUT: return %ExplicitGenericParam.call to %return.param
|
||||
// CHECK:STDOUT: return %ExplicitGenericParam.call
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -477,7 +477,7 @@ fn F() {
|
||||
// CHECK:STDOUT: %T.ref.loc4_71: type = name_ref T, %T.loc4_25.2 [symbolic = %T.loc4_25.1 (constants.%T)]
|
||||
// CHECK:STDOUT: %ExplicitGenericParam.specific_fn.loc4_50.1: <specific function> = specific_function %ExplicitGenericParam.ref, @ExplicitGenericParam(constants.%T) [symbolic = %ExplicitGenericParam.specific_fn.loc4_50.2 (constants.%ExplicitGenericParam.specific_fn)]
|
||||
// CHECK:STDOUT: %ExplicitGenericParam.call: init @ExplicitGenericParam.%ptr.loc4_39.1 (%ptr) = call %ExplicitGenericParam.specific_fn.loc4_50.1()
|
||||
// CHECK:STDOUT: return %ExplicitGenericParam.call to %return.param
|
||||
// CHECK:STDOUT: return %ExplicitGenericParam.call
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -632,7 +632,7 @@ fn F() {
|
||||
// CHECK:STDOUT: %x.ref: @ExplicitAndAlsoDeduced.%T.loc6_27.1 (%T) = name_ref x, %x
|
||||
// CHECK:STDOUT: %ExplicitAndAlsoDeduced.specific_fn.loc7_10.1: <specific function> = specific_function %ExplicitAndAlsoDeduced.ref, @ExplicitAndAlsoDeduced(constants.%T) [symbolic = %ExplicitAndAlsoDeduced.specific_fn.loc7_10.2 (constants.%ExplicitAndAlsoDeduced.specific_fn.7e7)]
|
||||
// CHECK:STDOUT: %ExplicitAndAlsoDeduced.call: init @ExplicitAndAlsoDeduced.%ptr.loc6_47.1 (%ptr.e8f) = call %ExplicitAndAlsoDeduced.specific_fn.loc7_10.1(%x.ref)
|
||||
// CHECK:STDOUT: return %ExplicitAndAlsoDeduced.call to %return.param
|
||||
// CHECK:STDOUT: return %ExplicitAndAlsoDeduced.call
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -650,7 +650,7 @@ fn F() {
|
||||
// CHECK:STDOUT: %ExplicitAndAlsoDeduced.call: init %ptr.643 = call %ExplicitAndAlsoDeduced.specific_fn(%.loc11_37.6)
|
||||
// CHECK:STDOUT: %DestroyOp.bound: <bound method> = bound_method %.loc11_37.4, constants.%DestroyOp
|
||||
// CHECK:STDOUT: %DestroyOp.call: init %empty_tuple.type = call %DestroyOp.bound(%.loc11_37.4)
|
||||
// CHECK:STDOUT: return %ExplicitAndAlsoDeduced.call to %return.param
|
||||
// CHECK:STDOUT: return %ExplicitAndAlsoDeduced.call
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @DestroyOp(%self.param: %A) = "no_op";
|
||||
@@ -786,7 +786,7 @@ fn F() {
|
||||
// CHECK:STDOUT: %x.ref: @ImplicitGenericParam.%T.loc4_25.1 (%T) = name_ref x, %x
|
||||
// CHECK:STDOUT: %ImplicitGenericParam.specific_fn.loc4_56.1: <specific function> = specific_function %ImplicitGenericParam.ref, @ImplicitGenericParam(constants.%T) [symbolic = %ImplicitGenericParam.specific_fn.loc4_56.2 (constants.%ImplicitGenericParam.specific_fn.7cc)]
|
||||
// CHECK:STDOUT: %ImplicitGenericParam.call: init @ImplicitGenericParam.%ptr.loc4_45.1 (%ptr.e8f) = call %ImplicitGenericParam.specific_fn.loc4_56.1(%x.ref)
|
||||
// CHECK:STDOUT: return %ImplicitGenericParam.call to %return.param
|
||||
// CHECK:STDOUT: return %ImplicitGenericParam.call
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -796,7 +796,7 @@ fn F() {
|
||||
// CHECK:STDOUT: %n.ref: %i32 = name_ref n, %n
|
||||
// CHECK:STDOUT: %ImplicitGenericParam.specific_fn: <specific function> = specific_function %ImplicitGenericParam.ref, @ImplicitGenericParam(constants.%i32) [concrete = constants.%ImplicitGenericParam.specific_fn.be5]
|
||||
// CHECK:STDOUT: %ImplicitGenericParam.call: init %ptr.235 = call %ImplicitGenericParam.specific_fn(%n.ref)
|
||||
// CHECK:STDOUT: return %ImplicitGenericParam.call to %return.param
|
||||
// CHECK:STDOUT: return %ImplicitGenericParam.call
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: specific @ImplicitGenericParam(constants.%T) {
|
||||
|
||||
@@ -64,7 +64,7 @@ fn F(T:! type, p: T**) -> T* {
|
||||
// CHECK:STDOUT: %specific_impl_fn.loc6_10.1: <specific function> = specific_impl_function %impl.elem0.loc6_10.1, @Copy.Op(constants.%Copy.facet) [symbolic = %specific_impl_fn.loc6_10.2 (constants.%specific_impl_fn.b84)]
|
||||
// CHECK:STDOUT: %bound_method.loc6_10.2: <bound method> = bound_method %.loc6_10.2, %specific_impl_fn.loc6_10.1
|
||||
// CHECK:STDOUT: %Copy.Op.call: init @F.%ptr.loc4_20.1 (%ptr.e8f) = call %bound_method.loc6_10.2(%.loc6_10.2)
|
||||
// CHECK:STDOUT: return %Copy.Op.call to %return.param
|
||||
// CHECK:STDOUT: return %Copy.Op.call
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
|
||||
@@ -167,7 +167,7 @@ fn F(U:! type, T:! type) -> U* {
|
||||
// CHECK:STDOUT: %T.ref.loc7: type = name_ref T, %T.loc6 [symbolic = %T.loc4_6.1 (constants.%T)]
|
||||
// CHECK:STDOUT: %F.specific_fn.loc7_10.1: <specific function> = specific_function %F.ref, @F(constants.%T) [symbolic = %F.specific_fn.loc7_10.2 (constants.%F.specific_fn)]
|
||||
// CHECK:STDOUT: %F.call: init @F.%ptr.loc4_20.1 (%ptr) = call %F.specific_fn.loc7_10.1()
|
||||
// CHECK:STDOUT: return %F.call to %return.param.loc6
|
||||
// CHECK:STDOUT: return %F.call
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -274,7 +274,7 @@ fn F(U:! type, T:! type) -> U* {
|
||||
// CHECK:STDOUT: !entry:
|
||||
// CHECK:STDOUT: %F.ref: %F.type.117dbc.1 = name_ref F, file.%F.decl.loc4 [concrete = constants.%F.d98bd5.1]
|
||||
// CHECK:STDOUT: %T.ref: type = name_ref T, %T.loc13_6.2 [symbolic = %T.loc13_6.1 (constants.%T)]
|
||||
// CHECK:STDOUT: return <error> to %return.param
|
||||
// CHECK:STDOUT: return <error>
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -388,7 +388,7 @@ fn F(U:! type, T:! type) -> U* {
|
||||
// CHECK:STDOUT: !entry:
|
||||
// CHECK:STDOUT: %F.ref: %F.type.117dbc.1 = name_ref F, file.%F.decl.loc4 [concrete = constants.%F.d98bd5.1]
|
||||
// CHECK:STDOUT: %T.ref.loc21: type = name_ref T, %T.loc13_16.2 [symbolic = %T.loc13_16.1 (constants.%T.091)]
|
||||
// CHECK:STDOUT: return <error> to %return.param
|
||||
// CHECK:STDOUT: return <error>
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -502,7 +502,7 @@ fn F(U:! type, T:! type) -> U* {
|
||||
// CHECK:STDOUT: !entry:
|
||||
// CHECK:STDOUT: %F.ref: %F.type.117dbc.1 = name_ref F, file.%F.decl.loc4 [concrete = constants.%F.d98bd5.1]
|
||||
// CHECK:STDOUT: %T.ref: type = name_ref T, %T.loc13_16.2 [symbolic = %T.loc13_16.1 (constants.%T.091)]
|
||||
// CHECK:STDOUT: return <error> to %return.param
|
||||
// CHECK:STDOUT: return <error>
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
|
||||
@@ -70,7 +70,7 @@ fn F(T:! type, n: T*) -> T* {
|
||||
// CHECK:STDOUT: %specific_impl_fn.loc7_10.1: <specific function> = specific_impl_function %impl.elem0.loc7_10.1, @Copy.Op(constants.%Copy.facet) [symbolic = %specific_impl_fn.loc7_10.2 (constants.%specific_impl_fn.b84)]
|
||||
// CHECK:STDOUT: %bound_method.loc7_10.2: <bound method> = bound_method %m.ref, %specific_impl_fn.loc7_10.1
|
||||
// CHECK:STDOUT: %Copy.Op.call: init @F.%ptr.loc4_20.1 (%ptr) = call %bound_method.loc7_10.2(%m.ref)
|
||||
// CHECK:STDOUT: return %Copy.Op.call to %return.param
|
||||
// CHECK:STDOUT: return %Copy.Op.call
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
|
||||
Reference in New Issue
Block a user