mirror of
https://github.com/carbon-language/carbon-lang.git
synced 2026-10-06 09:14:42 +01:00
Initial support for binding patterns in SemIR (#4221)
Introduces the `BindingPattern` and `SymbolicBindingPattern` insts, and a separate stack of pattern blocks that they are emitted into. The intent is to generate the corresponding pattern-matching insts (like `BindName`) from them in a separate pass, but that is deferred to future PRs. See [here](https://docs.google.com/document/d/1U_vQH17V893J9aF1LJXUnFYBNSs2MjKl4bJPaWCB2zo/edit?usp=sharing&resourcekey=0-w0xGYZ0An31Kpz-wvzSXwQ) for the design this is based on, but note that during review we have chosen to deviate from that design by putting the patterns in separate blocks, and omitting the "forward references" from a `BindingPattern` to its corresponding `BindName`. This in turn necessitates having separate inst kinds for symbolic and non-symbolic binding patterns. --------- Co-authored-by: Jon Ross-Perkins <jperkins@google.com>
This commit is contained in:
co-authored by
Jon Ross-Perkins
parent
87678cc374
commit
dc32aa2690
+31
-27
@@ -153,33 +153,37 @@ fn D() {}
|
||||
// CHECK:STDOUT: .D = %D.decl
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %Core.import = import Core
|
||||
// CHECK:STDOUT: %A.decl: %A.type = fn_decl @A [template = constants.%A] {}
|
||||
// CHECK:STDOUT: %A.decl: %A.type = fn_decl @A [template = constants.%A] {} {}
|
||||
// CHECK:STDOUT: %B.decl: %B.type = fn_decl @B [template = constants.%B] {
|
||||
// CHECK:STDOUT: %b.patt: i32 = binding_pattern b
|
||||
// CHECK:STDOUT: } {
|
||||
// CHECK:STDOUT: %int.make_type_32.loc5_9: init type = call constants.%Int32() [template = i32]
|
||||
// CHECK:STDOUT: %.loc5_9.1: type = value_of_initializer %int.make_type_32.loc5_9 [template = i32]
|
||||
// CHECK:STDOUT: %.loc5_9.2: type = converted %int.make_type_32.loc5_9, %.loc5_9.1 [template = i32]
|
||||
// CHECK:STDOUT: %b.loc5_6.1: i32 = param b, runtime_param0
|
||||
// CHECK:STDOUT: @B.%b: i32 = bind_name b, %b.loc5_6.1
|
||||
// CHECK:STDOUT: %b.param: i32 = param b, runtime_param0
|
||||
// CHECK:STDOUT: %b: i32 = bind_name b, %b.param
|
||||
// CHECK:STDOUT: %int.make_type_32.loc5_17: init type = call constants.%Int32() [template = i32]
|
||||
// CHECK:STDOUT: %.loc5_17.1: type = value_of_initializer %int.make_type_32.loc5_17 [template = i32]
|
||||
// CHECK:STDOUT: %.loc5_17.2: type = converted %int.make_type_32.loc5_17, %.loc5_17.1 [template = i32]
|
||||
// CHECK:STDOUT: @B.%return: ref i32 = var <return slot>
|
||||
// CHECK:STDOUT: %return: ref i32 = var <return slot>
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %C.decl: %C.type = fn_decl @C [template = constants.%C] {
|
||||
// CHECK:STDOUT: %c.patt: %.3 = binding_pattern c
|
||||
// CHECK:STDOUT: } {
|
||||
// CHECK:STDOUT: %int.make_type_32.loc6_10: init type = call constants.%Int32() [template = i32]
|
||||
// CHECK:STDOUT: %.loc6_14.1: %.2 = tuple_literal (%int.make_type_32.loc6_10)
|
||||
// CHECK:STDOUT: %.loc6_14.2: type = value_of_initializer %int.make_type_32.loc6_10 [template = i32]
|
||||
// CHECK:STDOUT: %.loc6_14.3: type = converted %int.make_type_32.loc6_10, %.loc6_14.2 [template = i32]
|
||||
// CHECK:STDOUT: %.loc6_14.4: type = converted %.loc6_14.1, constants.%.3 [template = constants.%.3]
|
||||
// CHECK:STDOUT: %c.loc6_6.1: %.3 = param c, runtime_param0
|
||||
// CHECK:STDOUT: @C.%c: %.3 = bind_name c, %c.loc6_6.1
|
||||
// CHECK:STDOUT: %c.param: %.3 = param c, runtime_param0
|
||||
// CHECK:STDOUT: %c: %.3 = bind_name c, %c.param
|
||||
// CHECK:STDOUT: %int.make_type_32.loc6_25: init type = call constants.%Int32() [template = i32]
|
||||
// CHECK:STDOUT: %.loc6_25.1: type = value_of_initializer %int.make_type_32.loc6_25 [template = i32]
|
||||
// CHECK:STDOUT: %.loc6_25.2: type = converted %int.make_type_32.loc6_25, %.loc6_25.1 [template = i32]
|
||||
// CHECK:STDOUT: %.loc6_28: type = struct_type {.c: i32} [template = constants.%.4]
|
||||
// CHECK:STDOUT: @C.%return: ref %.4 = var <return slot>
|
||||
// CHECK:STDOUT: %return: ref %.4 = var <return slot>
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %D.decl: %D.type = fn_decl @D [template = constants.%D] {}
|
||||
// CHECK:STDOUT: %D.decl: %D.type = fn_decl @D [template = constants.%D] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @A() {
|
||||
@@ -235,7 +239,7 @@ fn D() {}
|
||||
// CHECK:STDOUT: .A = %A.decl
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %Core.import = import Core
|
||||
// CHECK:STDOUT: %A.decl: %A.type = fn_decl @A [template = constants.%A] {}
|
||||
// CHECK:STDOUT: %A.decl: %A.type = fn_decl @A [template = constants.%A] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: extern fn @A();
|
||||
@@ -260,9 +264,9 @@ fn D() {}
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: imports {
|
||||
// CHECK:STDOUT: %import_ref.1: %A.type = import_ref Main//fns, inst+3, loaded [template = constants.%A]
|
||||
// CHECK:STDOUT: %import_ref.2: %B.type = import_ref Main//fns, inst+22, loaded [template = constants.%B]
|
||||
// CHECK:STDOUT: %import_ref.3: %C.type = import_ref Main//fns, inst+44, loaded [template = constants.%C]
|
||||
// CHECK:STDOUT: %import_ref.4 = import_ref Main//fns, inst+56, unloaded
|
||||
// CHECK:STDOUT: %import_ref.2: %B.type = import_ref Main//fns, inst+23, loaded [template = constants.%B]
|
||||
// CHECK:STDOUT: %import_ref.3: %C.type = import_ref Main//fns, inst+46, loaded [template = constants.%C]
|
||||
// CHECK:STDOUT: %import_ref.4 = import_ref Main//fns, inst+58, unloaded
|
||||
// CHECK:STDOUT: %Core: <namespace> = namespace file.%Core.import, [template] {
|
||||
// CHECK:STDOUT: .Int32 = %import_ref.5
|
||||
// CHECK:STDOUT: import Core//prelude
|
||||
@@ -348,9 +352,9 @@ fn D() {}
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: imports {
|
||||
// CHECK:STDOUT: %import_ref.1: %A.type = import_ref Main//fns, inst+3, loaded [template = constants.%A]
|
||||
// CHECK:STDOUT: %import_ref.2: %B.type = import_ref Main//fns, inst+22, loaded [template = constants.%B]
|
||||
// CHECK:STDOUT: %import_ref.3 = import_ref Main//fns, inst+44, unloaded
|
||||
// CHECK:STDOUT: %import_ref.4 = import_ref Main//fns, inst+56, unloaded
|
||||
// CHECK:STDOUT: %import_ref.2: %B.type = import_ref Main//fns, inst+23, loaded [template = constants.%B]
|
||||
// CHECK:STDOUT: %import_ref.3 = import_ref Main//fns, inst+46, unloaded
|
||||
// CHECK:STDOUT: %import_ref.4 = import_ref Main//fns, inst+58, unloaded
|
||||
// CHECK:STDOUT: %Core: <namespace> = namespace file.%Core.import, [template] {
|
||||
// CHECK:STDOUT: .Int32 = %import_ref.5
|
||||
// CHECK:STDOUT: import Core//prelude
|
||||
@@ -375,13 +379,13 @@ fn D() {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %Core.import = import Core
|
||||
// CHECK:STDOUT: %default.import = import <invalid>
|
||||
// CHECK:STDOUT: %A.decl: %A.type = fn_decl @A [template = constants.%A] {}
|
||||
// CHECK:STDOUT: %B.decl: %B.type = fn_decl @B [template = constants.%B] {
|
||||
// CHECK:STDOUT: %A.decl: %A.type = fn_decl @A [template = constants.%A] {} {}
|
||||
// CHECK:STDOUT: %B.decl: %B.type = fn_decl @B [template = constants.%B] {} {
|
||||
// CHECK:STDOUT: %int.make_type_32.loc23_9: init type = call constants.%Int32() [template = i32]
|
||||
// CHECK:STDOUT: %.loc23_9.1: type = value_of_initializer %int.make_type_32.loc23_9 [template = i32]
|
||||
// CHECK:STDOUT: %.loc23_9.2: type = converted %int.make_type_32.loc23_9, %.loc23_9.1 [template = i32]
|
||||
// CHECK:STDOUT: %b.loc23_6.1: i32 = param b, runtime_param0
|
||||
// CHECK:STDOUT: %b.loc23_6.2: i32 = bind_name b, %b.loc23_6.1
|
||||
// CHECK:STDOUT: %b.param: i32 = param b, runtime_param0
|
||||
// CHECK:STDOUT: %b.loc23: i32 = bind_name b, %b.param
|
||||
// CHECK:STDOUT: %int.make_type_32.loc23_17: init type = call constants.%Int32() [template = i32]
|
||||
// CHECK:STDOUT: %.loc23_17.1: type = value_of_initializer %int.make_type_32.loc23_17 [template = i32]
|
||||
// CHECK:STDOUT: %.loc23_17.2: type = converted %int.make_type_32.loc23_17, %.loc23_17.1 [template = i32]
|
||||
@@ -396,7 +400,7 @@ fn D() {}
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @Int32() -> type = "int.make_type_32";
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @B(%b: i32) -> i32;
|
||||
// CHECK:STDOUT: fn @B(%b.1: i32) -> i32;
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: --- fail_redecl_then_def.carbon
|
||||
// CHECK:STDOUT:
|
||||
@@ -427,8 +431,8 @@ fn D() {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %Core.import = import Core
|
||||
// CHECK:STDOUT: %default.import = import <invalid>
|
||||
// CHECK:STDOUT: %A.decl.loc14: %A.type = fn_decl @A [template = constants.%A] {}
|
||||
// CHECK:STDOUT: %A.decl.loc24: %A.type = fn_decl @A [template = constants.%A] {}
|
||||
// CHECK:STDOUT: %A.decl.loc14: %A.type = fn_decl @A [template = constants.%A] {} {}
|
||||
// CHECK:STDOUT: %A.decl.loc24: %A.type = fn_decl @A [template = constants.%A] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: extern fn @A() {
|
||||
@@ -446,9 +450,9 @@ fn D() {}
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: imports {
|
||||
// CHECK:STDOUT: %import_ref.1 = import_ref Main//fns, inst+3, unloaded
|
||||
// CHECK:STDOUT: %import_ref.2 = import_ref Main//fns, inst+22, unloaded
|
||||
// CHECK:STDOUT: %import_ref.3 = import_ref Main//fns, inst+44, unloaded
|
||||
// CHECK:STDOUT: %import_ref.4: %D.type = import_ref Main//fns, inst+56, loaded [template = constants.%D]
|
||||
// CHECK:STDOUT: %import_ref.2 = import_ref Main//fns, inst+23, unloaded
|
||||
// CHECK:STDOUT: %import_ref.3 = import_ref Main//fns, inst+46, unloaded
|
||||
// CHECK:STDOUT: %import_ref.4: %D.type = import_ref Main//fns, inst+58, loaded [template = constants.%D]
|
||||
// CHECK:STDOUT: %Core: <namespace> = namespace file.%Core.import, [template] {
|
||||
// CHECK:STDOUT: import Core//prelude
|
||||
// CHECK:STDOUT: import Core//prelude/operators
|
||||
@@ -471,8 +475,8 @@ fn D() {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %Core.import = import Core
|
||||
// CHECK:STDOUT: %default.import = import <invalid>
|
||||
// CHECK:STDOUT: %D.decl.loc13: %D.type = fn_decl @D [template = constants.%D] {}
|
||||
// CHECK:STDOUT: %D.decl.loc15: %D.type = fn_decl @D [template = constants.%D] {}
|
||||
// CHECK:STDOUT: %D.decl.loc13: %D.type = fn_decl @D [template = constants.%D] {} {}
|
||||
// CHECK:STDOUT: %D.decl.loc15: %D.type = fn_decl @D [template = constants.%D] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @D() {
|
||||
|
||||
@@ -162,7 +162,7 @@ private fn Redecl() {}
|
||||
// CHECK:STDOUT: .Def [private] = %Def.decl
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %Core.import = import Core
|
||||
// CHECK:STDOUT: %Def.decl: %Def.type = fn_decl @Def [template = constants.%Def] {}
|
||||
// CHECK:STDOUT: %Def.decl: %Def.type = fn_decl @Def [template = constants.%Def] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @Def() {
|
||||
@@ -197,8 +197,8 @@ private fn Redecl() {}
|
||||
// CHECK:STDOUT: .ForwardWithDef [private] = %ForwardWithDef.decl.loc4
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %Core.import = import Core
|
||||
// CHECK:STDOUT: %ForwardWithDef.decl.loc4: %ForwardWithDef.type = fn_decl @ForwardWithDef [template = constants.%ForwardWithDef] {}
|
||||
// CHECK:STDOUT: %ForwardWithDef.decl.loc6: %ForwardWithDef.type = fn_decl @ForwardWithDef [template = constants.%ForwardWithDef] {}
|
||||
// CHECK:STDOUT: %ForwardWithDef.decl.loc4: %ForwardWithDef.type = fn_decl @ForwardWithDef [template = constants.%ForwardWithDef] {} {}
|
||||
// CHECK:STDOUT: %ForwardWithDef.decl.loc6: %ForwardWithDef.type = fn_decl @ForwardWithDef [template = constants.%ForwardWithDef] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @ForwardWithDef() {
|
||||
@@ -233,7 +233,7 @@ private fn Redecl() {}
|
||||
// CHECK:STDOUT: .Forward [private] = %Forward.decl
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %Core.import = import Core
|
||||
// CHECK:STDOUT: %Forward.decl: %Forward.type = fn_decl @Forward [template = constants.%Forward] {}
|
||||
// CHECK:STDOUT: %Forward.decl: %Forward.type = fn_decl @Forward [template = constants.%Forward] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @Forward();
|
||||
@@ -533,7 +533,7 @@ private fn Redecl() {}
|
||||
// CHECK:STDOUT: %.loc4_9.2: type = converted %.loc4_9.1, constants.%.1 [template = constants.%.1]
|
||||
// CHECK:STDOUT: %f.var: ref %.1 = var f
|
||||
// CHECK:STDOUT: %f: ref %.1 = bind_name f, %f.var
|
||||
// CHECK:STDOUT: %Forward.decl: %Forward.type = fn_decl @Forward [template = constants.%Forward] {}
|
||||
// CHECK:STDOUT: %Forward.decl: %Forward.type = fn_decl @Forward [template = constants.%Forward] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @Forward() {
|
||||
@@ -659,8 +659,8 @@ private fn Redecl() {}
|
||||
// CHECK:STDOUT: .Redecl [private] = %Redecl.decl.loc4
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %Core.import = import Core
|
||||
// CHECK:STDOUT: %Redecl.decl.loc4: %Redecl.type = fn_decl @Redecl [template = constants.%Redecl] {}
|
||||
// CHECK:STDOUT: %Redecl.decl.loc6: %Redecl.type = fn_decl @Redecl [template = constants.%Redecl] {}
|
||||
// CHECK:STDOUT: %Redecl.decl.loc4: %Redecl.type = fn_decl @Redecl [template = constants.%Redecl] {} {}
|
||||
// CHECK:STDOUT: %Redecl.decl.loc6: %Redecl.type = fn_decl @Redecl [template = constants.%Redecl] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @Redecl() {
|
||||
|
||||
@@ -122,7 +122,7 @@ extern fn F() {}
|
||||
// CHECK:STDOUT: package: <namespace> = namespace [template] {
|
||||
// CHECK:STDOUT: .F = %F.decl
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {}
|
||||
// CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: extern fn @F() {
|
||||
@@ -142,8 +142,8 @@ extern fn F() {}
|
||||
// CHECK:STDOUT: package: <namespace> = namespace [template] {
|
||||
// CHECK:STDOUT: .F = %F.decl.loc4
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %F.decl.loc4: %F.type = fn_decl @F [template = constants.%F] {}
|
||||
// CHECK:STDOUT: %F.decl.loc5: %F.type = fn_decl @F [template = constants.%F] {}
|
||||
// CHECK:STDOUT: %F.decl.loc4: %F.type = fn_decl @F [template = constants.%F] {} {}
|
||||
// CHECK:STDOUT: %F.decl.loc5: %F.type = fn_decl @F [template = constants.%F] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: extern fn @F() {
|
||||
@@ -163,7 +163,7 @@ extern fn F() {}
|
||||
// CHECK:STDOUT: package: <namespace> = namespace [template] {
|
||||
// CHECK:STDOUT: .F = %F.decl
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {}
|
||||
// CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: extern fn @F();
|
||||
@@ -186,7 +186,7 @@ extern fn F() {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %default.import.loc2_6.1 = import <invalid>
|
||||
// CHECK:STDOUT: %default.import.loc2_6.2 = import <invalid>
|
||||
// CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {}
|
||||
// CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: extern fn @F() {
|
||||
@@ -206,8 +206,8 @@ extern fn F() {}
|
||||
// CHECK:STDOUT: package: <namespace> = namespace [template] {
|
||||
// CHECK:STDOUT: .F = %F.decl.loc4
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %F.decl.loc4: %F.type = fn_decl @F [template = constants.%F] {}
|
||||
// CHECK:STDOUT: %F.decl.loc12: %F.type = fn_decl @F [template = constants.%F] {}
|
||||
// CHECK:STDOUT: %F.decl.loc4: %F.type = fn_decl @F [template = constants.%F] {} {}
|
||||
// CHECK:STDOUT: %F.decl.loc12: %F.type = fn_decl @F [template = constants.%F] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: extern fn @F() {
|
||||
@@ -227,8 +227,8 @@ extern fn F() {}
|
||||
// CHECK:STDOUT: package: <namespace> = namespace [template] {
|
||||
// CHECK:STDOUT: .F = %F.decl.loc4
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %F.decl.loc4: %F.type = fn_decl @F [template = constants.%F] {}
|
||||
// CHECK:STDOUT: %F.decl.loc12: %F.type = fn_decl @F [template = constants.%F] {}
|
||||
// CHECK:STDOUT: %F.decl.loc4: %F.type = fn_decl @F [template = constants.%F] {} {}
|
||||
// CHECK:STDOUT: %F.decl.loc12: %F.type = fn_decl @F [template = constants.%F] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @F() {
|
||||
@@ -248,9 +248,9 @@ extern fn F() {}
|
||||
// CHECK:STDOUT: package: <namespace> = namespace [template] {
|
||||
// CHECK:STDOUT: .F = %F.decl.loc4
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %F.decl.loc4: %F.type = fn_decl @F [template = constants.%F] {}
|
||||
// CHECK:STDOUT: %F.decl.loc12: %F.type = fn_decl @F [template = constants.%F] {}
|
||||
// CHECK:STDOUT: %F.decl.loc20: %F.type = fn_decl @F [template = constants.%F] {}
|
||||
// CHECK:STDOUT: %F.decl.loc4: %F.type = fn_decl @F [template = constants.%F] {} {}
|
||||
// CHECK:STDOUT: %F.decl.loc12: %F.type = fn_decl @F [template = constants.%F] {} {}
|
||||
// CHECK:STDOUT: %F.decl.loc20: %F.type = fn_decl @F [template = constants.%F] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: extern fn @F() {
|
||||
@@ -270,8 +270,8 @@ extern fn F() {}
|
||||
// CHECK:STDOUT: package: <namespace> = namespace [template] {
|
||||
// CHECK:STDOUT: .F = %F.decl.loc4
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %F.decl.loc4: %F.type = fn_decl @F [template = constants.%F] {}
|
||||
// CHECK:STDOUT: %F.decl.loc12: %F.type = fn_decl @F [template = constants.%F] {}
|
||||
// CHECK:STDOUT: %F.decl.loc4: %F.type = fn_decl @F [template = constants.%F] {} {}
|
||||
// CHECK:STDOUT: %F.decl.loc12: %F.type = fn_decl @F [template = constants.%F] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @F() {
|
||||
@@ -299,7 +299,7 @@ extern fn F() {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %default.import.loc2_6.1 = import <invalid>
|
||||
// CHECK:STDOUT: %default.import.loc2_6.2 = import <invalid>
|
||||
// CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {}
|
||||
// CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: extern fn @F() {
|
||||
|
||||
+12
-12
@@ -119,7 +119,7 @@ extern fn F() {}
|
||||
// CHECK:STDOUT: package: <namespace> = namespace [template] {
|
||||
// CHECK:STDOUT: .F = %F.decl
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {}
|
||||
// CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: extern fn @F();
|
||||
@@ -136,7 +136,7 @@ extern fn F() {}
|
||||
// CHECK:STDOUT: package: <namespace> = namespace [template] {
|
||||
// CHECK:STDOUT: .F = %F.decl
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {}
|
||||
// CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: extern fn @F() {
|
||||
@@ -156,7 +156,7 @@ extern fn F() {}
|
||||
// CHECK:STDOUT: package: <namespace> = namespace [template] {
|
||||
// CHECK:STDOUT: .F = %F.decl
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {}
|
||||
// CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: extern fn @F();
|
||||
@@ -173,7 +173,7 @@ extern fn F() {}
|
||||
// CHECK:STDOUT: package: <namespace> = namespace [template] {
|
||||
// CHECK:STDOUT: .F = %F.decl
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {}
|
||||
// CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: extern fn @F();
|
||||
@@ -196,7 +196,7 @@ extern fn F() {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %default.import.loc2_6.1 = import <invalid>
|
||||
// CHECK:STDOUT: %default.import.loc2_6.2 = import <invalid>
|
||||
// CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {}
|
||||
// CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: extern fn @F() {
|
||||
@@ -216,7 +216,7 @@ extern fn F() {}
|
||||
// CHECK:STDOUT: package: <namespace> = namespace [template] {
|
||||
// CHECK:STDOUT: .F = %F.decl
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {}
|
||||
// CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: extern fn @F();
|
||||
@@ -233,7 +233,7 @@ extern fn F() {}
|
||||
// CHECK:STDOUT: package: <namespace> = namespace [template] {
|
||||
// CHECK:STDOUT: .F = %F.decl
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {}
|
||||
// CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: extern fn @F();
|
||||
@@ -256,7 +256,7 @@ extern fn F() {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %default.import.loc2_6.1 = import <invalid>
|
||||
// CHECK:STDOUT: %default.import.loc2_6.2 = import <invalid>
|
||||
// CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {}
|
||||
// CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: extern fn @F() {
|
||||
@@ -276,7 +276,7 @@ extern fn F() {}
|
||||
// CHECK:STDOUT: package: <namespace> = namespace [template] {
|
||||
// CHECK:STDOUT: .F = %F.decl
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {}
|
||||
// CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: extern fn @F();
|
||||
@@ -312,7 +312,7 @@ extern fn F() {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %default.import.loc2_6.1 = import <invalid>
|
||||
// CHECK:STDOUT: %default.import.loc2_6.2 = import <invalid>
|
||||
// CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {}
|
||||
// CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: extern fn @F() {
|
||||
@@ -332,7 +332,7 @@ extern fn F() {}
|
||||
// CHECK:STDOUT: package: <namespace> = namespace [template] {
|
||||
// CHECK:STDOUT: .F = %F.decl
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {}
|
||||
// CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: extern fn @F();
|
||||
@@ -361,7 +361,7 @@ extern fn F() {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %default.import.loc2_6.1 = import <invalid>
|
||||
// CHECK:STDOUT: %default.import.loc2_6.2 = import <invalid>
|
||||
// CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {}
|
||||
// CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: extern fn @F() {
|
||||
|
||||
+28
-20
@@ -106,51 +106,59 @@ fn K() -> {} { return {}; }
|
||||
// CHECK:STDOUT: .J = %J.decl
|
||||
// CHECK:STDOUT: .K = %K.decl
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {}
|
||||
// CHECK:STDOUT: %F.decl: %F.type = fn_decl @F [template = constants.%F] {} {}
|
||||
// CHECK:STDOUT: %.decl.loc19: %.type.1 = fn_decl @.1 [template = constants.%.2] {
|
||||
// CHECK:STDOUT: %x.patt: %.1 = binding_pattern x
|
||||
// CHECK:STDOUT: } {
|
||||
// CHECK:STDOUT: %.loc19_10.1: %.1 = tuple_literal ()
|
||||
// CHECK:STDOUT: %.loc19_10.2: type = converted %.loc19_10.1, constants.%.1 [template = constants.%.1]
|
||||
// CHECK:STDOUT: %x.loc19_6.1: %.1 = param x, runtime_param0
|
||||
// CHECK:STDOUT: @.1.%x: %.1 = bind_name x, %x.loc19_6.1
|
||||
// CHECK:STDOUT: %x.param: %.1 = param x, runtime_param0
|
||||
// CHECK:STDOUT: %x: %.1 = bind_name x, %x.param
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %G.decl: %G.type = fn_decl @G [template = constants.%G] {
|
||||
// CHECK:STDOUT: %x.patt: %.1 = binding_pattern x
|
||||
// CHECK:STDOUT: } {
|
||||
// CHECK:STDOUT: %.loc21_10.1: %.1 = tuple_literal ()
|
||||
// CHECK:STDOUT: %.loc21_10.2: type = converted %.loc21_10.1, constants.%.1 [template = constants.%.1]
|
||||
// CHECK:STDOUT: %x.loc21_6.1: %.1 = param x, runtime_param0
|
||||
// CHECK:STDOUT: @G.%x: %.1 = bind_name x, %x.loc21_6.1
|
||||
// CHECK:STDOUT: %x.param: %.1 = param x, runtime_param0
|
||||
// CHECK:STDOUT: %x: %.1 = bind_name x, %x.param
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %.decl.loc29: %.type.2 = fn_decl @.2 [template = constants.%.3] {}
|
||||
// CHECK:STDOUT: %.decl.loc29: %.type.2 = fn_decl @.2 [template = constants.%.3] {} {}
|
||||
// CHECK:STDOUT: %H.decl: %H.type = fn_decl @H [template = constants.%H] {
|
||||
// CHECK:STDOUT: %x.patt: %.1 = binding_pattern x
|
||||
// CHECK:STDOUT: } {
|
||||
// CHECK:STDOUT: %.loc31_10.1: %.1 = tuple_literal ()
|
||||
// CHECK:STDOUT: %.loc31_10.2: type = converted %.loc31_10.1, constants.%.1 [template = constants.%.1]
|
||||
// CHECK:STDOUT: %x.loc31_6.1: %.1 = param x, runtime_param0
|
||||
// CHECK:STDOUT: @H.%x: %.1 = bind_name x, %x.loc31_6.1
|
||||
// CHECK:STDOUT: %x.param: %.1 = param x, runtime_param0
|
||||
// CHECK:STDOUT: %x: %.1 = bind_name x, %x.param
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %.decl.loc36: %.type.3 = fn_decl @.3 [template = constants.%.4] {
|
||||
// CHECK:STDOUT: %x.loc36_6.1: <error> = param x, runtime_param0
|
||||
// CHECK:STDOUT: @.3.%x: <error> = bind_name x, %x.loc36_6.1
|
||||
// CHECK:STDOUT: %x.patt: <error> = binding_pattern x
|
||||
// CHECK:STDOUT: } {
|
||||
// CHECK:STDOUT: %x.param: <error> = param x, runtime_param0
|
||||
// CHECK:STDOUT: %x: <error> = bind_name x, %x.param
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %I.decl: %I.type = fn_decl @I [template = constants.%I] {}
|
||||
// CHECK:STDOUT: %.decl.loc46: %.type.4 = fn_decl @.4 [template = constants.%.5] {
|
||||
// CHECK:STDOUT: %I.decl: %I.type = fn_decl @I [template = constants.%I] {} {}
|
||||
// CHECK:STDOUT: %.decl.loc46: %.type.4 = fn_decl @.4 [template = constants.%.5] {} {
|
||||
// CHECK:STDOUT: %.loc46_12.1: %.1 = tuple_literal ()
|
||||
// CHECK:STDOUT: %.loc46_12.2: type = converted %.loc46_12.1, constants.%.1 [template = constants.%.1]
|
||||
// CHECK:STDOUT: @.4.%return: ref %.1 = var <return slot>
|
||||
// CHECK:STDOUT: %return: ref %.1 = var <return slot>
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %J.decl: %J.type = fn_decl @J [template = constants.%J] {
|
||||
// CHECK:STDOUT: %J.decl: %J.type = fn_decl @J [template = constants.%J] {} {
|
||||
// CHECK:STDOUT: %.loc48_12.1: %.1 = tuple_literal ()
|
||||
// CHECK:STDOUT: %.loc48_12.2: type = converted %.loc48_12.1, constants.%.1 [template = constants.%.1]
|
||||
// CHECK:STDOUT: @J.%return: ref %.1 = var <return slot>
|
||||
// CHECK:STDOUT: %return: ref %.1 = var <return slot>
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %.decl.loc56: %.type.5 = fn_decl @.5 [template = constants.%.6] {}
|
||||
// CHECK:STDOUT: %K.decl: %K.type = fn_decl @K [template = constants.%K] {
|
||||
// CHECK:STDOUT: %.decl.loc56: %.type.5 = fn_decl @.5 [template = constants.%.6] {} {}
|
||||
// CHECK:STDOUT: %K.decl: %K.type = fn_decl @K [template = constants.%K] {} {
|
||||
// CHECK:STDOUT: %.loc58_12.1: %.1 = tuple_literal ()
|
||||
// CHECK:STDOUT: %.loc58_12.2: type = converted %.loc58_12.1, constants.%.1 [template = constants.%.1]
|
||||
// CHECK:STDOUT: @K.%return: ref %.1 = var <return slot>
|
||||
// CHECK:STDOUT: %return: ref %.1 = var <return slot>
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %.decl.loc65: %.type.6 = fn_decl @.6 [template = constants.%.8] {
|
||||
// CHECK:STDOUT: %.decl.loc65: %.type.6 = fn_decl @.6 [template = constants.%.8] {} {
|
||||
// CHECK:STDOUT: %.loc65_12.1: %.7 = struct_literal ()
|
||||
// CHECK:STDOUT: %.loc65_12.2: type = converted %.loc65_12.1, constants.%.7 [template = constants.%.7]
|
||||
// CHECK:STDOUT: @.6.%return: ref %.7 = var <return slot>
|
||||
// CHECK:STDOUT: %return: ref %.7 = var <return slot>
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
|
||||
@@ -29,8 +29,8 @@ fn F() {}
|
||||
// CHECK:STDOUT: package: <namespace> = namespace [template] {
|
||||
// CHECK:STDOUT: .F = %F.decl.loc11
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %F.decl.loc11: %F.type = fn_decl @F [template = constants.%F] {}
|
||||
// CHECK:STDOUT: %F.decl.loc18: %F.type = fn_decl @F [template = constants.%F] {}
|
||||
// CHECK:STDOUT: %F.decl.loc11: %F.type = fn_decl @F [template = constants.%F] {} {}
|
||||
// CHECK:STDOUT: %F.decl.loc18: %F.type = fn_decl @F [template = constants.%F] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @F() {
|
||||
|
||||
+2
-2
@@ -24,8 +24,8 @@ fn Foo() {}
|
||||
// CHECK:STDOUT: package: <namespace> = namespace [template] {
|
||||
// CHECK:STDOUT: .Foo = %Foo.decl.loc11
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %Foo.decl.loc11: %Foo.type = fn_decl @Foo [template = constants.%Foo] {}
|
||||
// CHECK:STDOUT: %Foo.decl.loc13: %Foo.type = fn_decl @Foo [template = constants.%Foo] {}
|
||||
// CHECK:STDOUT: %Foo.decl.loc11: %Foo.type = fn_decl @Foo [template = constants.%Foo] {} {}
|
||||
// CHECK:STDOUT: %Foo.decl.loc13: %Foo.type = fn_decl @Foo [template = constants.%Foo] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @Foo() {
|
||||
|
||||
+12
-12
@@ -132,7 +132,7 @@ fn B() {}
|
||||
// CHECK:STDOUT: package: <namespace> = namespace [template] {
|
||||
// CHECK:STDOUT: .A = %A.decl
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %A.decl: %A.type = fn_decl @A [template = constants.%A] {}
|
||||
// CHECK:STDOUT: %A.decl: %A.type = fn_decl @A [template = constants.%A] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @A();
|
||||
@@ -155,7 +155,7 @@ fn B() {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %default.import.loc2_6.1 = import <invalid>
|
||||
// CHECK:STDOUT: %default.import.loc2_6.2 = import <invalid>
|
||||
// CHECK:STDOUT: %A.decl: %A.type = fn_decl @A [template = constants.%A] {}
|
||||
// CHECK:STDOUT: %A.decl: %A.type = fn_decl @A [template = constants.%A] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @A() {
|
||||
@@ -175,7 +175,7 @@ fn B() {}
|
||||
// CHECK:STDOUT: package: <namespace> = namespace [template] {
|
||||
// CHECK:STDOUT: .A = %A.decl
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %A.decl: %A.type = fn_decl @A [template = constants.%A] {}
|
||||
// CHECK:STDOUT: %A.decl: %A.type = fn_decl @A [template = constants.%A] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: extern fn @A();
|
||||
@@ -198,7 +198,7 @@ fn B() {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %default.import.loc2_6.1 = import <invalid>
|
||||
// CHECK:STDOUT: %default.import.loc2_6.2 = import <invalid>
|
||||
// CHECK:STDOUT: %A.decl: %A.type = fn_decl @A [template = constants.%A] {}
|
||||
// CHECK:STDOUT: %A.decl: %A.type = fn_decl @A [template = constants.%A] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: extern fn @A() {
|
||||
@@ -218,7 +218,7 @@ fn B() {}
|
||||
// CHECK:STDOUT: package: <namespace> = namespace [template] {
|
||||
// CHECK:STDOUT: .A = %A.decl
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %A.decl: %A.type = fn_decl @A [template = constants.%A] {}
|
||||
// CHECK:STDOUT: %A.decl: %A.type = fn_decl @A [template = constants.%A] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @A();
|
||||
@@ -241,7 +241,7 @@ fn B() {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %default.import.loc2_6.1 = import <invalid>
|
||||
// CHECK:STDOUT: %default.import.loc2_6.2 = import <invalid>
|
||||
// CHECK:STDOUT: %A.decl: %A.type = fn_decl @A [template = constants.%A] {}
|
||||
// CHECK:STDOUT: %A.decl: %A.type = fn_decl @A [template = constants.%A] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @A() {
|
||||
@@ -261,7 +261,7 @@ fn B() {}
|
||||
// CHECK:STDOUT: package: <namespace> = namespace [template] {
|
||||
// CHECK:STDOUT: .A = %A.decl
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %A.decl: %A.type = fn_decl @A [template = constants.%A] {}
|
||||
// CHECK:STDOUT: %A.decl: %A.type = fn_decl @A [template = constants.%A] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @A() {
|
||||
@@ -287,7 +287,7 @@ fn B() {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %default.import.loc2_6.1 = import <invalid>
|
||||
// CHECK:STDOUT: %default.import.loc2_6.2 = import <invalid>
|
||||
// CHECK:STDOUT: %A.decl: %A.type = fn_decl @A [template = constants.%A] {}
|
||||
// CHECK:STDOUT: %A.decl: %A.type = fn_decl @A [template = constants.%A] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @A();
|
||||
@@ -304,7 +304,7 @@ fn B() {}
|
||||
// CHECK:STDOUT: package: <namespace> = namespace [template] {
|
||||
// CHECK:STDOUT: .A = %A.decl
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %A.decl: %A.type = fn_decl @A [template = constants.%A] {}
|
||||
// CHECK:STDOUT: %A.decl: %A.type = fn_decl @A [template = constants.%A] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @A() {
|
||||
@@ -330,7 +330,7 @@ fn B() {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %default.import.loc2_6.1 = import <invalid>
|
||||
// CHECK:STDOUT: %default.import.loc2_6.2 = import <invalid>
|
||||
// CHECK:STDOUT: %A.decl: %A.type = fn_decl @A [template = constants.%A] {}
|
||||
// CHECK:STDOUT: %A.decl: %A.type = fn_decl @A [template = constants.%A] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @A() {
|
||||
@@ -351,7 +351,7 @@ fn B() {}
|
||||
// CHECK:STDOUT: .A = %A.decl
|
||||
// CHECK:STDOUT: .B = %B
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %A.decl: %A.type = fn_decl @A [template = constants.%A] {}
|
||||
// CHECK:STDOUT: %A.decl: %A.type = fn_decl @A [template = constants.%A] {} {}
|
||||
// CHECK:STDOUT: %A.ref: %A.type = name_ref A, %A.decl [template = constants.%A]
|
||||
// CHECK:STDOUT: %B: %A.type = bind_alias B, %A.decl [template = constants.%A]
|
||||
// CHECK:STDOUT: }
|
||||
@@ -380,7 +380,7 @@ fn B() {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %default.import.loc2_6.1 = import <invalid>
|
||||
// CHECK:STDOUT: %default.import.loc2_6.2 = import <invalid>
|
||||
// CHECK:STDOUT: %.decl: %.type = fn_decl @.1 [template = constants.%.2] {}
|
||||
// CHECK:STDOUT: %.decl: %.type = fn_decl @.1 [template = constants.%.2] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @A();
|
||||
|
||||
@@ -30,9 +30,9 @@ fn Baz() {}
|
||||
// CHECK:STDOUT: .Bar = %Bar.decl
|
||||
// CHECK:STDOUT: .Baz = %Baz.decl
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %Foo.decl: %Foo.type = fn_decl @Foo [template = constants.%Foo] {}
|
||||
// CHECK:STDOUT: %Bar.decl: %Bar.type = fn_decl @Bar [template = constants.%Bar] {}
|
||||
// CHECK:STDOUT: %Baz.decl: %Baz.type = fn_decl @Baz [template = constants.%Baz] {}
|
||||
// CHECK:STDOUT: %Foo.decl: %Foo.type = fn_decl @Foo [template = constants.%Foo] {} {}
|
||||
// CHECK:STDOUT: %Bar.decl: %Bar.type = fn_decl @Bar [template = constants.%Bar] {} {}
|
||||
// CHECK:STDOUT: %Baz.decl: %Baz.type = fn_decl @Baz [template = constants.%Baz] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @Foo() {
|
||||
|
||||
@@ -22,7 +22,7 @@ fn Foo() {}
|
||||
// CHECK:STDOUT: package: <namespace> = namespace [template] {
|
||||
// CHECK:STDOUT: .Foo = %Foo.decl
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %Foo.decl: %Foo.type = fn_decl @Foo [template = constants.%Foo] {}
|
||||
// CHECK:STDOUT: %Foo.decl: %Foo.type = fn_decl @Foo [template = constants.%Foo] {} {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @Foo() {
|
||||
|
||||
+147
-99
@@ -189,28 +189,36 @@ fn Foo(a: const (const C)) {}
|
||||
// CHECK:STDOUT: .Foo = %Foo.decl.loc7
|
||||
// CHECK:STDOUT: .Bar = %Bar.decl.loc10
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %C.decl: type = class_decl @C [template = constants.%C] {}
|
||||
// CHECK:STDOUT: %C.ref.loc5: type = name_ref C, %C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %C.decl: type = class_decl @C [template = constants.%C] {} {}
|
||||
// CHECK:STDOUT: %C.ref: type = name_ref C, %C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %D: type = bind_alias D, %C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %Foo.decl.loc7: %Foo.type = fn_decl @Foo [template = constants.%Foo] {
|
||||
// CHECK:STDOUT: %C.ref.loc7: type = name_ref C, %C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.loc7_8.1: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: %a.loc7_8.2: %C = bind_name a, %a.loc7_8.1
|
||||
// CHECK:STDOUT: %a.patt: %C = binding_pattern a
|
||||
// CHECK:STDOUT: } {
|
||||
// CHECK:STDOUT: %C.ref.loc7: type = name_ref C, file.%C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.param.loc7: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: %a.loc7: %C = bind_name a, %a.param.loc7
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %Foo.decl.loc8: %Foo.type = fn_decl @Foo [template = constants.%Foo] {
|
||||
// CHECK:STDOUT: %C.ref.loc8: type = name_ref C, %C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.loc8_8.1: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: @Foo.%a: %C = bind_name a, %a.loc8_8.1
|
||||
// CHECK:STDOUT: %a.patt: %C = binding_pattern a
|
||||
// CHECK:STDOUT: } {
|
||||
// CHECK:STDOUT: %C.ref.loc8: type = name_ref C, file.%C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.param.loc8: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: %a.loc8: %C = bind_name a, %a.param.loc8
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %Bar.decl.loc10: %Bar.type = fn_decl @Bar [template = constants.%Bar] {
|
||||
// CHECK:STDOUT: %D.ref.loc10: type = name_ref D, %D [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.loc10_8.1: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: %a.loc10_8.2: %C = bind_name a, %a.loc10_8.1
|
||||
// CHECK:STDOUT: %a.patt: %C = binding_pattern a
|
||||
// CHECK:STDOUT: } {
|
||||
// CHECK:STDOUT: %D.ref.loc10: type = name_ref D, file.%D [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.param.loc10: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: %a.loc10: %C = bind_name a, %a.param.loc10
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %Bar.decl.loc11: %Bar.type = fn_decl @Bar [template = constants.%Bar] {
|
||||
// CHECK:STDOUT: %D.ref.loc11: type = name_ref D, %D [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.loc11_8.1: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: @Bar.%a: %C = bind_name a, %a.loc11_8.1
|
||||
// CHECK:STDOUT: %a.patt: %C = binding_pattern a
|
||||
// CHECK:STDOUT: } {
|
||||
// CHECK:STDOUT: %D.ref.loc11: type = name_ref D, file.%D [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.param.loc11: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: %a.loc11: %C = bind_name a, %a.param.loc11
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -221,12 +229,12 @@ fn Foo(a: const (const C)) {}
|
||||
// CHECK:STDOUT: .Self = constants.%C
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @Foo(%a: %C) {
|
||||
// CHECK:STDOUT: fn @Foo(%a.loc8: %C) {
|
||||
// CHECK:STDOUT: !entry:
|
||||
// CHECK:STDOUT: return
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @Bar(%a: %C) {
|
||||
// CHECK:STDOUT: fn @Bar(%a.loc11: %C) {
|
||||
// CHECK:STDOUT: !entry:
|
||||
// CHECK:STDOUT: return
|
||||
// CHECK:STDOUT: }
|
||||
@@ -248,16 +256,20 @@ fn Foo(a: const (const C)) {}
|
||||
// CHECK:STDOUT: .C = %C.decl
|
||||
// CHECK:STDOUT: .Foo = %Foo.decl.loc6
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %C.decl: type = class_decl @C [template = constants.%C] {}
|
||||
// CHECK:STDOUT: %C.decl: type = class_decl @C [template = constants.%C] {} {}
|
||||
// CHECK:STDOUT: %Foo.decl.loc6: %Foo.type = fn_decl @Foo [template = constants.%Foo] {
|
||||
// CHECK:STDOUT: %C.ref.loc6: type = name_ref C, %C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.loc6_14.1: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: %a.loc6_14.2: %C = bind_name a, %a.loc6_14.1
|
||||
// CHECK:STDOUT: %a.patt: %C = binding_pattern a
|
||||
// CHECK:STDOUT: } {
|
||||
// CHECK:STDOUT: %C.ref.loc6: type = name_ref C, file.%C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.param.loc6: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: %a.loc6: %C = bind_name a, %a.param.loc6
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %Foo.decl.loc7: %Foo.type = fn_decl @Foo [template = constants.%Foo] {
|
||||
// CHECK:STDOUT: %C.ref.loc7: type = name_ref C, %C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.loc7_10.1: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: @Foo.%a: %C = bind_name a, %a.loc7_10.1
|
||||
// CHECK:STDOUT: %a.patt: %C = binding_pattern a
|
||||
// CHECK:STDOUT: } {
|
||||
// CHECK:STDOUT: %C.ref.loc7: type = name_ref C, file.%C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.param.loc7: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: %a.loc7: %C = bind_name a, %a.param.loc7
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -268,7 +280,7 @@ fn Foo(a: const (const C)) {}
|
||||
// CHECK:STDOUT: .Self = constants.%C
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @Foo[](%a: %C) {
|
||||
// CHECK:STDOUT: fn @Foo[](%a.loc7: %C) {
|
||||
// CHECK:STDOUT: !entry:
|
||||
// CHECK:STDOUT: return
|
||||
// CHECK:STDOUT: }
|
||||
@@ -292,16 +304,20 @@ fn Foo(a: const (const C)) {}
|
||||
// CHECK:STDOUT: .C = %C.decl
|
||||
// CHECK:STDOUT: .Foo = %Foo.decl
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %C.decl: type = class_decl @C [template = constants.%C] {}
|
||||
// CHECK:STDOUT: %C.decl: type = class_decl @C [template = constants.%C] {} {}
|
||||
// CHECK:STDOUT: %Foo.decl: %Foo.type = fn_decl @Foo [template = constants.%Foo] {
|
||||
// CHECK:STDOUT: %C.ref.loc6: type = name_ref C, %C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.loc6_8.1: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: @Foo.%a: %C = bind_name a, %a.loc6_8.1
|
||||
// CHECK:STDOUT: %a.patt: %C = binding_pattern a
|
||||
// CHECK:STDOUT: } {
|
||||
// CHECK:STDOUT: %C.ref: type = name_ref C, file.%C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.param: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: %a: %C = bind_name a, %a.param
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %.decl: %.type = fn_decl @.1 [template = constants.%.4] {
|
||||
// CHECK:STDOUT: %C.ref.loc14: type = name_ref C, %C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.loc14_8.1: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: @.1.%a: %C = bind_name a, %a.loc14_8.1
|
||||
// CHECK:STDOUT: %a.patt: %C = binding_pattern a
|
||||
// CHECK:STDOUT: } {
|
||||
// CHECK:STDOUT: %C.ref: type = name_ref C, file.%C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.param: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: %a: %C = bind_name a, %a.param
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -336,16 +352,20 @@ fn Foo(a: const (const C)) {}
|
||||
// CHECK:STDOUT: .C = %C.decl
|
||||
// CHECK:STDOUT: .Foo = %Foo.decl.loc6
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %C.decl: type = class_decl @C [template = constants.%C] {}
|
||||
// CHECK:STDOUT: %C.decl: type = class_decl @C [template = constants.%C] {} {}
|
||||
// CHECK:STDOUT: %Foo.decl.loc6: %Foo.type = fn_decl @Foo [template = constants.%Foo] {
|
||||
// CHECK:STDOUT: %C.ref.loc6: type = name_ref C, %C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.loc6_8.1: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: %a.loc6_8.2: %C = bind_name a, %a.loc6_8.1
|
||||
// CHECK:STDOUT: %a.patt: %C = binding_pattern a
|
||||
// CHECK:STDOUT: } {
|
||||
// CHECK:STDOUT: %C.ref.loc6: type = name_ref C, file.%C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.param.loc6: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: %a.loc6: %C = bind_name a, %a.param.loc6
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %Foo.decl.loc7: %Foo.type = fn_decl @Foo [template = constants.%Foo] {
|
||||
// CHECK:STDOUT: %C.ref.loc7: type = name_ref C, %C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.loc7_8.1: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: @Foo.%a: %C = bind_name a, %a.loc7_8.1
|
||||
// CHECK:STDOUT: %a.patt: %C = binding_pattern a
|
||||
// CHECK:STDOUT: } {
|
||||
// CHECK:STDOUT: %C.ref.loc7: type = name_ref C, file.%C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.param.loc7: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: %a.loc7: %C = bind_name a, %a.param.loc7
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -356,7 +376,7 @@ fn Foo(a: const (const C)) {}
|
||||
// CHECK:STDOUT: .Self = constants.%C
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: fn @Foo(%a: %C) {
|
||||
// CHECK:STDOUT: fn @Foo(%a.loc7: %C) {
|
||||
// CHECK:STDOUT: !entry:
|
||||
// CHECK:STDOUT: return
|
||||
// CHECK:STDOUT: }
|
||||
@@ -381,18 +401,22 @@ fn Foo(a: const (const C)) {}
|
||||
// CHECK:STDOUT: .Foo = %Foo.decl
|
||||
// CHECK:STDOUT: .Bar = %Bar.decl
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %C.decl: type = class_decl @C [template = constants.%C] {}
|
||||
// CHECK:STDOUT: %C.ref.loc5: type = name_ref C, %C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %C.decl: type = class_decl @C [template = constants.%C] {} {}
|
||||
// CHECK:STDOUT: %C.ref: type = name_ref C, %C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %D: type = bind_alias D, %C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %Foo.decl: %Foo.type = fn_decl @Foo [template = constants.%Foo] {
|
||||
// CHECK:STDOUT: %C.ref.loc7: type = name_ref C, %C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.loc7_8.1: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: @Foo.%a: %C = bind_name a, %a.loc7_8.1
|
||||
// CHECK:STDOUT: %a.patt: %C = binding_pattern a
|
||||
// CHECK:STDOUT: } {
|
||||
// CHECK:STDOUT: %C.ref: type = name_ref C, file.%C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.param: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: %a: %C = bind_name a, %a.param
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %Bar.decl: %Bar.type = fn_decl @Bar [template = constants.%Bar] {
|
||||
// CHECK:STDOUT: %D.ref: type = name_ref D, %D [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.loc8_8.1: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: @Bar.%a: %C = bind_name a, %a.loc8_8.1
|
||||
// CHECK:STDOUT: %a.patt: %C = binding_pattern a
|
||||
// CHECK:STDOUT: } {
|
||||
// CHECK:STDOUT: %D.ref: type = name_ref D, file.%D [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.param: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: %a: %C = bind_name a, %a.param
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -424,8 +448,8 @@ fn Foo(a: const (const C)) {}
|
||||
// CHECK:STDOUT: imports {
|
||||
// CHECK:STDOUT: %import_ref.1: type = import_ref Main//two_file, inst+1, loaded [template = constants.%C]
|
||||
// CHECK:STDOUT: %import_ref.2: type = import_ref Main//two_file, inst+7, loaded [template = constants.%C]
|
||||
// CHECK:STDOUT: %import_ref.3: %Foo.type = import_ref Main//two_file, inst+11, loaded [template = constants.%Foo]
|
||||
// CHECK:STDOUT: %import_ref.4: %Bar.type = import_ref Main//two_file, inst+18, loaded [template = constants.%Bar]
|
||||
// CHECK:STDOUT: %import_ref.3: %Foo.type = import_ref Main//two_file, inst+12, loaded [template = constants.%Foo]
|
||||
// CHECK:STDOUT: %import_ref.4: %Bar.type = import_ref Main//two_file, inst+20, loaded [template = constants.%Bar]
|
||||
// CHECK:STDOUT: %import_ref.5 = import_ref Main//two_file, inst+2, unloaded
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -439,14 +463,18 @@ fn Foo(a: const (const C)) {}
|
||||
// CHECK:STDOUT: %default.import.loc2_6.1 = import <invalid>
|
||||
// CHECK:STDOUT: %default.import.loc2_6.2 = import <invalid>
|
||||
// CHECK:STDOUT: %Foo.decl: %Foo.type = fn_decl @Foo [template = constants.%Foo] {
|
||||
// CHECK:STDOUT: %a.patt: %C = binding_pattern a
|
||||
// CHECK:STDOUT: } {
|
||||
// CHECK:STDOUT: %C.ref: type = name_ref C, imports.%import_ref.1 [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.loc4_8.1: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: @Foo.%a: %C = bind_name a, %a.loc4_8.1
|
||||
// CHECK:STDOUT: %a.param: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: %a: %C = bind_name a, %a.param
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %Bar.decl: %Bar.type = fn_decl @Bar [template = constants.%Bar] {
|
||||
// CHECK:STDOUT: %a.patt: %C = binding_pattern a
|
||||
// CHECK:STDOUT: } {
|
||||
// CHECK:STDOUT: %D.ref: type = name_ref D, imports.%import_ref.2 [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.loc5_8.1: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: @Bar.%a: %C = bind_name a, %a.loc5_8.1
|
||||
// CHECK:STDOUT: %a.param: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: %a: %C = bind_name a, %a.param
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -485,18 +513,22 @@ fn Foo(a: const (const C)) {}
|
||||
// CHECK:STDOUT: .D = %D
|
||||
// CHECK:STDOUT: .Foo = %Foo.decl
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %C.decl: type = class_decl @C [template = constants.%C] {}
|
||||
// CHECK:STDOUT: %C.ref.loc5: type = name_ref C, %C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %C.decl: type = class_decl @C [template = constants.%C] {} {}
|
||||
// CHECK:STDOUT: %C.ref: type = name_ref C, %C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %D: type = bind_alias D, %C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %Foo.decl: %Foo.type = fn_decl @Foo [template = constants.%Foo] {
|
||||
// CHECK:STDOUT: %C.ref.loc7: type = name_ref C, %C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.loc7_8.1: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: @Foo.%a: %C = bind_name a, %a.loc7_8.1
|
||||
// CHECK:STDOUT: %a.patt: %C = binding_pattern a
|
||||
// CHECK:STDOUT: } {
|
||||
// CHECK:STDOUT: %C.ref: type = name_ref C, file.%C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.param: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: %a: %C = bind_name a, %a.param
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %.decl: %.type = fn_decl @.1 [template = constants.%.4] {
|
||||
// CHECK:STDOUT: %D.ref: type = name_ref D, %D [template = constants.%C]
|
||||
// CHECK:STDOUT: %b.loc15_8.1: %C = param b, runtime_param0
|
||||
// CHECK:STDOUT: @.1.%b: %C = bind_name b, %b.loc15_8.1
|
||||
// CHECK:STDOUT: %b.patt: %C = binding_pattern b
|
||||
// CHECK:STDOUT: } {
|
||||
// CHECK:STDOUT: %D.ref: type = name_ref D, file.%D [template = constants.%C]
|
||||
// CHECK:STDOUT: %b.param: %C = param b, runtime_param0
|
||||
// CHECK:STDOUT: %b: %C = bind_name b, %b.param
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -534,18 +566,22 @@ fn Foo(a: const (const C)) {}
|
||||
// CHECK:STDOUT: .D = %D
|
||||
// CHECK:STDOUT: .Foo = %Foo.decl
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %C.decl: type = class_decl @C [template = constants.%C] {}
|
||||
// CHECK:STDOUT: %C.ref.loc5: type = name_ref C, %C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %C.decl: type = class_decl @C [template = constants.%C] {} {}
|
||||
// CHECK:STDOUT: %C.ref: type = name_ref C, %C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %D: type = bind_alias D, %C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %Foo.decl: %Foo.type = fn_decl @Foo [template = constants.%Foo] {
|
||||
// CHECK:STDOUT: %C.ref.loc7: type = name_ref C, %C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.loc7_8.1: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: @Foo.%a: %C = bind_name a, %a.loc7_8.1
|
||||
// CHECK:STDOUT: %a.patt: %C = binding_pattern a
|
||||
// CHECK:STDOUT: } {
|
||||
// CHECK:STDOUT: %C.ref: type = name_ref C, file.%C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.param: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: %a: %C = bind_name a, %a.param
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %.decl: %.type = fn_decl @.1 [template = constants.%.4] {
|
||||
// CHECK:STDOUT: %D.ref: type = name_ref D, %D [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.loc15_8.1: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: @.1.%a: %C = bind_name a, %a.loc15_8.1
|
||||
// CHECK:STDOUT: %a.patt: %C = binding_pattern a
|
||||
// CHECK:STDOUT: } {
|
||||
// CHECK:STDOUT: %D.ref: type = name_ref D, file.%D [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.param: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: %a: %C = bind_name a, %a.param
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -583,18 +619,22 @@ fn Foo(a: const (const C)) {}
|
||||
// CHECK:STDOUT: .D = %D
|
||||
// CHECK:STDOUT: .Foo = %Foo.decl
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %C.decl: type = class_decl @C [template = constants.%C] {}
|
||||
// CHECK:STDOUT: %C.ref.loc5: type = name_ref C, %C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %C.decl: type = class_decl @C [template = constants.%C] {} {}
|
||||
// CHECK:STDOUT: %C.ref: type = name_ref C, %C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %D: type = bind_alias D, %C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %Foo.decl: %Foo.type = fn_decl @Foo [template = constants.%Foo] {
|
||||
// CHECK:STDOUT: %C.ref.loc7: type = name_ref C, %C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.loc7_8.1: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: @Foo.%a: %C = bind_name a, %a.loc7_8.1
|
||||
// CHECK:STDOUT: %a.patt: %C = binding_pattern a
|
||||
// CHECK:STDOUT: } {
|
||||
// CHECK:STDOUT: %C.ref: type = name_ref C, file.%C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.param: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: %a: %C = bind_name a, %a.param
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %.decl: %.type = fn_decl @.1 [template = constants.%.4] {
|
||||
// CHECK:STDOUT: %D.ref: type = name_ref D, %D [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.loc15_8.1: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: @.1.%a: %C = bind_name a, %a.loc15_8.1
|
||||
// CHECK:STDOUT: %a.patt: %C = binding_pattern a
|
||||
// CHECK:STDOUT: } {
|
||||
// CHECK:STDOUT: %D.ref: type = name_ref D, file.%D [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.param: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: %a: %C = bind_name a, %a.param
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -631,16 +671,16 @@ fn Foo(a: const (const C)) {}
|
||||
// CHECK:STDOUT: .D = %D
|
||||
// CHECK:STDOUT: .Foo = %Foo.decl.loc7
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %C.decl: type = class_decl @C [template = constants.%C] {}
|
||||
// CHECK:STDOUT: %C.ref.loc5: type = name_ref C, %C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %C.decl: type = class_decl @C [template = constants.%C] {} {}
|
||||
// CHECK:STDOUT: %C.ref: type = name_ref C, %C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %D: type = bind_alias D, %C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %Foo.decl.loc7: %Foo.type = fn_decl @Foo [template = constants.%Foo] {
|
||||
// CHECK:STDOUT: %C.ref.loc7: type = name_ref C, %C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %Foo.decl.loc7: %Foo.type = fn_decl @Foo [template = constants.%Foo] {} {
|
||||
// CHECK:STDOUT: %C.ref: type = name_ref C, file.%C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %return.var.loc7: ref %C = var <return slot>
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %Foo.decl.loc8: %Foo.type = fn_decl @Foo [template = constants.%Foo] {
|
||||
// CHECK:STDOUT: %D.ref: type = name_ref D, %D [template = constants.%C]
|
||||
// CHECK:STDOUT: @Foo.%return: ref %C = var <return slot>
|
||||
// CHECK:STDOUT: %Foo.decl.loc8: %Foo.type = fn_decl @Foo [template = constants.%Foo] {} {
|
||||
// CHECK:STDOUT: %D.ref: type = name_ref D, file.%D [template = constants.%C]
|
||||
// CHECK:STDOUT: %return: ref %C = var <return slot>
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -675,11 +715,13 @@ fn Foo(a: const (const C)) {}
|
||||
// CHECK:STDOUT: .C = %C.decl
|
||||
// CHECK:STDOUT: .Foo = %Foo.decl
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %C.decl: type = class_decl @C [template = constants.%C] {}
|
||||
// CHECK:STDOUT: %C.decl: type = class_decl @C [template = constants.%C] {} {}
|
||||
// CHECK:STDOUT: %Foo.decl: %Foo.type = fn_decl @Foo [template = constants.%Foo] {
|
||||
// CHECK:STDOUT: %C.ref: type = name_ref C, %C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.loc6_8.1: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: @Foo.%a: %C = bind_name a, %a.loc6_8.1
|
||||
// CHECK:STDOUT: %a.patt: %C = binding_pattern a
|
||||
// CHECK:STDOUT: } {
|
||||
// CHECK:STDOUT: %C.ref: type = name_ref C, file.%C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.param: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: %a: %C = bind_name a, %a.param
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -706,7 +748,7 @@ fn Foo(a: const (const C)) {}
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: imports {
|
||||
// CHECK:STDOUT: %import_ref.1: type = import_ref Main//alias_two_file, inst+1, loaded [template = constants.%C]
|
||||
// CHECK:STDOUT: %import_ref.2: %Foo.type = import_ref Main//alias_two_file, inst+9, loaded [template = constants.%Foo]
|
||||
// CHECK:STDOUT: %import_ref.2: %Foo.type = import_ref Main//alias_two_file, inst+10, loaded [template = constants.%Foo]
|
||||
// CHECK:STDOUT: %import_ref.3 = import_ref Main//alias_two_file, inst+2, unloaded
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -721,9 +763,11 @@ fn Foo(a: const (const C)) {}
|
||||
// CHECK:STDOUT: %C.ref: type = name_ref C, imports.%import_ref.1 [template = constants.%C]
|
||||
// CHECK:STDOUT: %D: type = bind_alias D, imports.%import_ref.1 [template = constants.%C]
|
||||
// CHECK:STDOUT: %Foo.decl: %Foo.type = fn_decl @Foo [template = constants.%Foo] {
|
||||
// CHECK:STDOUT: %D.ref: type = name_ref D, %D [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.loc6_8.1: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: @Foo.%a: %C = bind_name a, %a.loc6_8.1
|
||||
// CHECK:STDOUT: %a.patt: %C = binding_pattern a
|
||||
// CHECK:STDOUT: } {
|
||||
// CHECK:STDOUT: %D.ref: type = name_ref D, file.%D [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.param: %C = param a, runtime_param0
|
||||
// CHECK:STDOUT: %a: %C = bind_name a, %a.param
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
@@ -757,19 +801,23 @@ fn Foo(a: const (const C)) {}
|
||||
// CHECK:STDOUT: .C = %C.decl
|
||||
// CHECK:STDOUT: .Foo = %Foo.decl
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %C.decl: type = class_decl @C [template = constants.%C] {}
|
||||
// CHECK:STDOUT: %C.decl: type = class_decl @C [template = constants.%C] {} {}
|
||||
// CHECK:STDOUT: %Foo.decl: %Foo.type = fn_decl @Foo [template = constants.%Foo] {
|
||||
// CHECK:STDOUT: %C.ref.loc6: type = name_ref C, %C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.patt: %.3 = binding_pattern a
|
||||
// CHECK:STDOUT: } {
|
||||
// CHECK:STDOUT: %C.ref: type = name_ref C, file.%C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %.loc6: type = const_type %C [template = constants.%.3]
|
||||
// CHECK:STDOUT: %a.loc6_8.1: %.3 = param a, runtime_param0
|
||||
// CHECK:STDOUT: @Foo.%a: %.3 = bind_name a, %a.loc6_8.1
|
||||
// CHECK:STDOUT: %a.param: %.3 = param a, runtime_param0
|
||||
// CHECK:STDOUT: %a: %.3 = bind_name a, %a.param
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %.decl: %.type = fn_decl @.1 [template = constants.%.5] {
|
||||
// CHECK:STDOUT: %C.ref.loc17: type = name_ref C, %C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %a.patt: %.3 = binding_pattern a
|
||||
// CHECK:STDOUT: } {
|
||||
// CHECK:STDOUT: %C.ref: type = name_ref C, file.%C.decl [template = constants.%C]
|
||||
// CHECK:STDOUT: %.loc17_18: type = const_type %C [template = constants.%.3]
|
||||
// CHECK:STDOUT: %.loc17_11: type = const_type %.3 [template = constants.%.3]
|
||||
// CHECK:STDOUT: %a.loc17_8.1: %.3 = param a, runtime_param0
|
||||
// CHECK:STDOUT: @.1.%a: %.3 = bind_name a, %a.loc17_8.1
|
||||
// CHECK:STDOUT: %a.param: %.3 = param a, runtime_param0
|
||||
// CHECK:STDOUT: %a: %.3 = bind_name a, %a.param
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
|
||||
@@ -42,11 +42,13 @@ fn Foo(a: i32) {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %Core.import = import Core
|
||||
// CHECK:STDOUT: %Foo.decl: %Foo.type = fn_decl @Foo [template = constants.%Foo] {
|
||||
// CHECK:STDOUT: %a.patt: i32 = binding_pattern a
|
||||
// CHECK:STDOUT: } {
|
||||
// CHECK:STDOUT: %int.make_type_32: init type = call constants.%Int32() [template = i32]
|
||||
// CHECK:STDOUT: %.loc11_11.1: type = value_of_initializer %int.make_type_32 [template = i32]
|
||||
// CHECK:STDOUT: %.loc11_11.2: type = converted %int.make_type_32, %.loc11_11.1 [template = i32]
|
||||
// CHECK:STDOUT: %a.loc11_8.1: i32 = param a, runtime_param0
|
||||
// CHECK:STDOUT: @Foo.%a: i32 = bind_name a, %a.loc11_8.1
|
||||
// CHECK:STDOUT: %a.param: i32 = param a, runtime_param0
|
||||
// CHECK:STDOUT: %a: i32 = bind_name a, %a.param
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
|
||||
@@ -42,11 +42,13 @@ fn Foo(a: i32,) {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %Core.import = import Core
|
||||
// CHECK:STDOUT: %Foo.decl: %Foo.type = fn_decl @Foo [template = constants.%Foo] {
|
||||
// CHECK:STDOUT: %a.patt: i32 = binding_pattern a
|
||||
// CHECK:STDOUT: } {
|
||||
// CHECK:STDOUT: %int.make_type_32: init type = call constants.%Int32() [template = i32]
|
||||
// CHECK:STDOUT: %.loc11_11.1: type = value_of_initializer %int.make_type_32 [template = i32]
|
||||
// CHECK:STDOUT: %.loc11_11.2: type = converted %int.make_type_32, %.loc11_11.1 [template = i32]
|
||||
// CHECK:STDOUT: %a.loc11_8.1: i32 = param a, runtime_param0
|
||||
// CHECK:STDOUT: @Foo.%a: i32 = bind_name a, %a.loc11_8.1
|
||||
// CHECK:STDOUT: %a.param: i32 = param a, runtime_param0
|
||||
// CHECK:STDOUT: %a: i32 = bind_name a, %a.param
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
|
||||
@@ -42,16 +42,19 @@ fn Foo(a: i32, b: i32) {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %Core.import = import Core
|
||||
// CHECK:STDOUT: %Foo.decl: %Foo.type = fn_decl @Foo [template = constants.%Foo] {
|
||||
// CHECK:STDOUT: %a.patt: i32 = binding_pattern a
|
||||
// CHECK:STDOUT: %b.patt: i32 = binding_pattern b
|
||||
// CHECK:STDOUT: } {
|
||||
// CHECK:STDOUT: %int.make_type_32.loc11_11: init type = call constants.%Int32() [template = i32]
|
||||
// CHECK:STDOUT: %.loc11_11.1: type = value_of_initializer %int.make_type_32.loc11_11 [template = i32]
|
||||
// CHECK:STDOUT: %.loc11_11.2: type = converted %int.make_type_32.loc11_11, %.loc11_11.1 [template = i32]
|
||||
// CHECK:STDOUT: %a.loc11_8.1: i32 = param a, runtime_param0
|
||||
// CHECK:STDOUT: @Foo.%a: i32 = bind_name a, %a.loc11_8.1
|
||||
// CHECK:STDOUT: %a.param: i32 = param a, runtime_param0
|
||||
// CHECK:STDOUT: %a: i32 = bind_name a, %a.param
|
||||
// CHECK:STDOUT: %int.make_type_32.loc11_19: init type = call constants.%Int32() [template = i32]
|
||||
// CHECK:STDOUT: %.loc11_19.1: type = value_of_initializer %int.make_type_32.loc11_19 [template = i32]
|
||||
// CHECK:STDOUT: %.loc11_19.2: type = converted %int.make_type_32.loc11_19, %.loc11_19.1 [template = i32]
|
||||
// CHECK:STDOUT: %b.loc11_16.1: i32 = param b, runtime_param1
|
||||
// CHECK:STDOUT: @Foo.%b: i32 = bind_name b, %b.loc11_16.1
|
||||
// CHECK:STDOUT: %b.param: i32 = param b, runtime_param1
|
||||
// CHECK:STDOUT: %b: i32 = bind_name b, %b.param
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
|
||||
@@ -42,16 +42,19 @@ fn Foo(a: i32, b: i32,) {}
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: %Core.import = import Core
|
||||
// CHECK:STDOUT: %Foo.decl: %Foo.type = fn_decl @Foo [template = constants.%Foo] {
|
||||
// CHECK:STDOUT: %a.patt: i32 = binding_pattern a
|
||||
// CHECK:STDOUT: %b.patt: i32 = binding_pattern b
|
||||
// CHECK:STDOUT: } {
|
||||
// CHECK:STDOUT: %int.make_type_32.loc11_11: init type = call constants.%Int32() [template = i32]
|
||||
// CHECK:STDOUT: %.loc11_11.1: type = value_of_initializer %int.make_type_32.loc11_11 [template = i32]
|
||||
// CHECK:STDOUT: %.loc11_11.2: type = converted %int.make_type_32.loc11_11, %.loc11_11.1 [template = i32]
|
||||
// CHECK:STDOUT: %a.loc11_8.1: i32 = param a, runtime_param0
|
||||
// CHECK:STDOUT: @Foo.%a: i32 = bind_name a, %a.loc11_8.1
|
||||
// CHECK:STDOUT: %a.param: i32 = param a, runtime_param0
|
||||
// CHECK:STDOUT: %a: i32 = bind_name a, %a.param
|
||||
// CHECK:STDOUT: %int.make_type_32.loc11_19: init type = call constants.%Int32() [template = i32]
|
||||
// CHECK:STDOUT: %.loc11_19.1: type = value_of_initializer %int.make_type_32.loc11_19 [template = i32]
|
||||
// CHECK:STDOUT: %.loc11_19.2: type = converted %int.make_type_32.loc11_19, %.loc11_19.1 [template = i32]
|
||||
// CHECK:STDOUT: %b.loc11_16.1: i32 = param b, runtime_param1
|
||||
// CHECK:STDOUT: @Foo.%b: i32 = bind_name b, %b.loc11_16.1
|
||||
// CHECK:STDOUT: %b.param: i32 = param b, runtime_param1
|
||||
// CHECK:STDOUT: %b: i32 = bind_name b, %b.param
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
|
||||
Reference in New Issue
Block a user