From 17f53a23a548dbd0bc8341b5017b52e2f67ae241 Mon Sep 17 00:00:00 2001 From: Ayaz Hafiz Date: Mon, 18 Jul 2022 15:10:22 -0400 Subject: [PATCH] Update tests --- crates/compiler/solve/tests/solve_expr.rs | 8 +- .../compiler/test_mono/generated/encode.txt | 18 +- .../encode_derived_nested_record_string.txt | 270 +++++++++--------- ...encode_derived_record_one_field_string.txt | 148 +++++----- ...ncode_derived_record_two_field_strings.txt | 146 +++++----- .../generated/encode_derived_string.txt | 26 +- .../encode_derived_tag_one_field_string.txt | 158 +++++----- ...encode_derived_tag_two_payloads_string.txt | 156 +++++----- ...ursive_alias_multiple_polymorphic_expr.txt | 6 +- ...ed_as_recursive_alias_polymorphic_expr.txt | 4 +- ..._annotated_as_recursive_alias_toplevel.txt | 4 +- .../compiler/test_mono/generated/is_nil.txt | 4 +- ...cialize_errors_behind_unified_branches.txt | 4 +- .../test_mono/generated/issue_2810.txt | 4 +- .../generated/opaque_assign_to_symbol.txt | 4 +- crates/compiler/test_mono/generated/peano.txt | 4 +- .../compiler/test_mono/generated/peano1.txt | 6 +- .../compiler/test_mono/generated/peano2.txt | 10 +- .../generated/specialize_ability_call.txt | 4 +- crates/reporting/tests/test_reporting.rs | 8 +- 20 files changed, 496 insertions(+), 496 deletions(-) diff --git a/crates/compiler/solve/tests/solve_expr.rs b/crates/compiler/solve/tests/solve_expr.rs index ddfb7cb863..ff29bdee0d 100644 --- a/crates/compiler/solve/tests/solve_expr.rs +++ b/crates/compiler/solve/tests/solve_expr.rs @@ -6166,11 +6166,11 @@ mod solve_expr { mulHashes = \x, y -> hash x * hash y - Id := U64 - hash = \@Id n -> n + Id := U64 has [Hash { hash: hashId }] + hashId = \@Id n -> n - Three := {} - hash = \@Three _ -> 3 + Three := {} has [Hash { hash: hashThree }] + hashThree = \@Three _ -> 3 result = mulHashes (@Id 100) (@Three {}) "# diff --git a/crates/compiler/test_mono/generated/encode.txt b/crates/compiler/test_mono/generated/encode.txt index b63c00d749..cee8705043 100644 --- a/crates/compiler/test_mono/generated/encode.txt +++ b/crates/compiler/test_mono/generated/encode.txt @@ -12,22 +12,22 @@ procedure List.66 (#Attr.2, #Attr.3): let List.298 : List U8 = lowlevel ListAppendUnsafe #Attr.2 #Attr.3; ret List.298; -procedure Test.20 (Test.22): - let Test.34 : {U8} = Struct {Test.22}; - ret Test.34; - -procedure Test.21 (Test.27): - let Test.33 : {U8} = CallByName Test.20 Test.27; - ret Test.33; - procedure Test.23 (Test.24, Test.35, #Attr.12): let Test.22 : U8 = StructAtIndex 0 #Attr.12; let Test.37 : List U8 = CallByName List.4 Test.24 Test.22; ret Test.37; +procedure Test.8 (Test.22): + let Test.34 : {U8} = Struct {Test.22}; + ret Test.34; + +procedure Test.9 (Test.27): + let Test.33 : {U8} = CallByName Test.8 Test.27; + ret Test.33; + procedure Test.0 (): let Test.32 : U8 = 15i64; - let Test.28 : {U8} = CallByName Test.21 Test.32; + let Test.28 : {U8} = CallByName Test.9 Test.32; let Test.30 : List U8 = Array []; let Test.31 : {} = Struct {}; let Test.29 : List U8 = CallByName Test.23 Test.30 Test.31 Test.28; diff --git a/crates/compiler/test_mono/generated/encode_derived_nested_record_string.txt b/crates/compiler/test_mono/generated/encode_derived_nested_record_string.txt index 6182bbb065..74df4d60bb 100644 --- a/crates/compiler/test_mono/generated/encode_derived_nested_record_string.txt +++ b/crates/compiler/test_mono/generated/encode_derived_nested_record_string.txt @@ -52,7 +52,7 @@ procedure Encode.23 (Encode.94, Encode.102, Encode.96): ret Encode.106; procedure Encode.23 (Encode.94, Encode.102, Encode.96): - let Encode.113 : List U8 = CallByName Json.77 Encode.94 Encode.96 Encode.102; + let Encode.113 : List U8 = CallByName Json.81 Encode.94 Encode.96 Encode.102; ret Encode.113; procedure Encode.23 (Encode.94, Encode.102, Encode.96): @@ -60,7 +60,7 @@ procedure Encode.23 (Encode.94, Encode.102, Encode.96): ret Encode.115; procedure Encode.23 (Encode.94, Encode.102, Encode.96): - let Encode.125 : List U8 = CallByName Json.77 Encode.94 Encode.96 Encode.102; + let Encode.125 : List U8 = CallByName Json.81 Encode.94 Encode.96 Encode.102; ret Encode.125; procedure Encode.23 (Encode.94, Encode.102, Encode.96): @@ -74,165 +74,165 @@ procedure Encode.25 (Encode.100, Encode.101): ret Encode.103; procedure Json.1 (): - let Json.102 : {} = Struct {}; - ret Json.102; + let Json.106 : {} = Struct {}; + ret Json.106; procedure Json.17 (Json.64): - let Json.149 : {Str} = Struct {Json.64}; - let Json.148 : {Str} = CallByName Encode.22 Json.149; - ret Json.148; + let Json.153 : {Str} = Struct {Json.64}; + let Json.152 : {Str} = CallByName Encode.22 Json.153; + ret Json.152; -procedure Json.19 (Json.76): - let Json.104 : {List {Str, {Str}}} = Struct {Json.76}; - let Json.103 : {List {Str, {Str}}} = CallByName Encode.22 Json.104; - ret Json.103; +procedure Json.19 (Json.80): + let Json.108 : {List {Str, {Str}}} = Struct {Json.80}; + let Json.107 : {List {Str, {Str}}} = CallByName Encode.22 Json.108; + ret Json.107; -procedure Json.19 (Json.76): - let Json.146 : {List {Str, {Str}}} = Struct {Json.76}; - let Json.145 : {List {Str, {Str}}} = CallByName Encode.22 Json.146; - ret Json.145; +procedure Json.19 (Json.80): + let Json.150 : {List {Str, {Str}}} = Struct {Json.80}; + let Json.149 : {List {Str, {Str}}} = CallByName Encode.22 Json.150; + ret Json.149; -procedure Json.65 (Json.66, Json.150, #Attr.12): +procedure Json.65 (Json.66, Json.154, #Attr.12): let Json.64 : Str = StructAtIndex 0 #Attr.12; inc Json.64; dec #Attr.12; + let Json.194 : I32 = 34i64; + let Json.193 : U8 = CallByName Num.123 Json.194; + let Json.191 : List U8 = CallByName List.4 Json.66 Json.193; + let Json.192 : List U8 = CallByName Str.12 Json.64; + let Json.188 : List U8 = CallByName List.8 Json.191 Json.192; let Json.190 : I32 = 34i64; let Json.189 : U8 = CallByName Num.123 Json.190; - let Json.187 : List U8 = CallByName List.4 Json.66 Json.189; - let Json.188 : List U8 = CallByName Str.12 Json.64; - let Json.184 : List U8 = CallByName List.8 Json.187 Json.188; - let Json.186 : I32 = 34i64; - let Json.185 : U8 = CallByName Num.123 Json.186; - let Json.183 : List U8 = CallByName List.4 Json.184 Json.185; - ret Json.183; + let Json.187 : List U8 = CallByName List.4 Json.188 Json.189; + ret Json.187; -procedure Json.77 (Json.78, Json.105, #Attr.12): - let Json.76 : List {Str, {Str}} = StructAtIndex 0 #Attr.12; - inc Json.76; +procedure Json.81 (Json.82, Json.109, #Attr.12): + let Json.80 : List {Str, {Str}} = StructAtIndex 0 #Attr.12; + inc Json.80; dec #Attr.12; - let Json.138 : I32 = 123i64; - let Json.137 : U8 = CallByName Num.123 Json.138; - let Json.80 : List U8 = CallByName List.4 Json.78 Json.137; - let Json.136 : U64 = CallByName List.6 Json.76; - let Json.113 : {List U8, U64} = Struct {Json.80, Json.136}; - let Json.114 : {} = Struct {}; - let Json.112 : {List U8, U64} = CallByName List.18 Json.76 Json.113 Json.114; - dec Json.76; - let Json.82 : List U8 = StructAtIndex 0 Json.112; - inc Json.82; - dec Json.112; - let Json.111 : I32 = 125i64; - let Json.110 : U8 = CallByName Num.123 Json.111; - let Json.109 : List U8 = CallByName List.4 Json.82 Json.110; - ret Json.109; - -procedure Json.77 (Json.78, Json.105, #Attr.12): - let Json.76 : List {Str, {Str}} = StructAtIndex 0 #Attr.12; - inc Json.76; - dec #Attr.12; - let Json.181 : I32 = 123i64; - let Json.180 : U8 = CallByName Num.123 Json.181; - let Json.80 : List U8 = CallByName List.4 Json.78 Json.180; - let Json.179 : U64 = CallByName List.6 Json.76; - let Json.156 : {List U8, U64} = Struct {Json.80, Json.179}; - let Json.157 : {} = Struct {}; - let Json.155 : {List U8, U64} = CallByName List.18 Json.76 Json.156 Json.157; - dec Json.76; - let Json.82 : List U8 = StructAtIndex 0 Json.155; - inc Json.82; - dec Json.155; - let Json.154 : I32 = 125i64; - let Json.153 : U8 = CallByName Num.123 Json.154; - let Json.152 : List U8 = CallByName List.4 Json.82 Json.153; - ret Json.152; - -procedure Json.79 (Json.107, Json.108): - let Json.85 : Str = StructAtIndex 0 Json.108; - inc Json.85; - let Json.86 : {Str} = StructAtIndex 1 Json.108; + let Json.142 : I32 = 123i64; + let Json.141 : U8 = CallByName Num.123 Json.142; + let Json.84 : List U8 = CallByName List.4 Json.82 Json.141; + let Json.140 : U64 = CallByName List.6 Json.80; + let Json.117 : {List U8, U64} = Struct {Json.84, Json.140}; + let Json.118 : {} = Struct {}; + let Json.116 : {List U8, U64} = CallByName List.18 Json.80 Json.117 Json.118; + dec Json.80; + let Json.86 : List U8 = StructAtIndex 0 Json.116; inc Json.86; - dec Json.108; - let Json.83 : List U8 = StructAtIndex 0 Json.107; - inc Json.83; - let Json.84 : U64 = StructAtIndex 1 Json.107; - dec Json.107; + dec Json.116; + let Json.115 : I32 = 125i64; + let Json.114 : U8 = CallByName Num.123 Json.115; + let Json.113 : List U8 = CallByName List.4 Json.86 Json.114; + ret Json.113; + +procedure Json.81 (Json.82, Json.109, #Attr.12): + let Json.80 : List {Str, {Str}} = StructAtIndex 0 #Attr.12; + inc Json.80; + dec #Attr.12; + let Json.185 : I32 = 123i64; + let Json.184 : U8 = CallByName Num.123 Json.185; + let Json.84 : List U8 = CallByName List.4 Json.82 Json.184; + let Json.183 : U64 = CallByName List.6 Json.80; + let Json.160 : {List U8, U64} = Struct {Json.84, Json.183}; + let Json.161 : {} = Struct {}; + let Json.159 : {List U8, U64} = CallByName List.18 Json.80 Json.160 Json.161; + dec Json.80; + let Json.86 : List U8 = StructAtIndex 0 Json.159; + inc Json.86; + dec Json.159; + let Json.158 : I32 = 125i64; + let Json.157 : U8 = CallByName Num.123 Json.158; + let Json.156 : List U8 = CallByName List.4 Json.86 Json.157; + ret Json.156; + +procedure Json.83 (Json.111, Json.112): + let Json.89 : Str = StructAtIndex 0 Json.112; + inc Json.89; + let Json.90 : {Str} = StructAtIndex 1 Json.112; + inc Json.90; + dec Json.112; + let Json.87 : List U8 = StructAtIndex 0 Json.111; + inc Json.87; + let Json.88 : U64 = StructAtIndex 1 Json.111; + dec Json.111; + let Json.139 : I32 = 34i64; + let Json.138 : U8 = CallByName Num.123 Json.139; + let Json.136 : List U8 = CallByName List.4 Json.87 Json.138; + let Json.137 : List U8 = CallByName Str.12 Json.89; + let Json.133 : List U8 = CallByName List.8 Json.136 Json.137; let Json.135 : I32 = 34i64; let Json.134 : U8 = CallByName Num.123 Json.135; - let Json.132 : List U8 = CallByName List.4 Json.83 Json.134; - let Json.133 : List U8 = CallByName Str.12 Json.85; - let Json.129 : List U8 = CallByName List.8 Json.132 Json.133; - let Json.131 : I32 = 34i64; - let Json.130 : U8 = CallByName Num.123 Json.131; - let Json.126 : List U8 = CallByName List.4 Json.129 Json.130; - let Json.128 : I32 = 58i64; - let Json.127 : U8 = CallByName Num.123 Json.128; - let Json.124 : List U8 = CallByName List.4 Json.126 Json.127; - let Json.125 : {} = Struct {}; - let Json.87 : List U8 = CallByName Encode.23 Json.124 Json.86 Json.125; - joinpoint Json.119 Json.88: - let Json.117 : U64 = 1i64; - let Json.116 : U64 = CallByName Num.20 Json.84 Json.117; - let Json.115 : {List U8, U64} = Struct {Json.88, Json.116}; - ret Json.115; + let Json.130 : List U8 = CallByName List.4 Json.133 Json.134; + let Json.132 : I32 = 58i64; + let Json.131 : U8 = CallByName Num.123 Json.132; + let Json.128 : List U8 = CallByName List.4 Json.130 Json.131; + let Json.129 : {} = Struct {}; + let Json.91 : List U8 = CallByName Encode.23 Json.128 Json.90 Json.129; + joinpoint Json.123 Json.92: + let Json.121 : U64 = 1i64; + let Json.120 : U64 = CallByName Num.20 Json.88 Json.121; + let Json.119 : {List U8, U64} = Struct {Json.92, Json.120}; + ret Json.119; in - let Json.123 : U64 = 0i64; - let Json.120 : Int1 = CallByName Num.24 Json.84 Json.123; - if Json.120 then - let Json.122 : I32 = 44i64; - let Json.121 : U8 = CallByName Num.123 Json.122; - let Json.118 : List U8 = CallByName List.4 Json.87 Json.121; - jump Json.119 Json.118; + let Json.127 : U64 = 1i64; + let Json.124 : Int1 = CallByName Num.24 Json.88 Json.127; + if Json.124 then + let Json.126 : I32 = 44i64; + let Json.125 : U8 = CallByName Num.123 Json.126; + let Json.122 : List U8 = CallByName List.4 Json.91 Json.125; + jump Json.123 Json.122; else - jump Json.119 Json.87; + jump Json.123 Json.91; -procedure Json.79 (Json.107, Json.108): - let Json.85 : Str = StructAtIndex 0 Json.108; - inc Json.85; - let Json.86 : {Str} = StructAtIndex 1 Json.108; - inc Json.86; - dec Json.108; - let Json.83 : List U8 = StructAtIndex 0 Json.107; - inc Json.83; - let Json.84 : U64 = StructAtIndex 1 Json.107; - dec Json.107; +procedure Json.83 (Json.111, Json.112): + let Json.89 : Str = StructAtIndex 0 Json.112; + inc Json.89; + let Json.90 : {Str} = StructAtIndex 1 Json.112; + inc Json.90; + dec Json.112; + let Json.87 : List U8 = StructAtIndex 0 Json.111; + inc Json.87; + let Json.88 : U64 = StructAtIndex 1 Json.111; + dec Json.111; + let Json.182 : I32 = 34i64; + let Json.181 : U8 = CallByName Num.123 Json.182; + let Json.179 : List U8 = CallByName List.4 Json.87 Json.181; + let Json.180 : List U8 = CallByName Str.12 Json.89; + let Json.176 : List U8 = CallByName List.8 Json.179 Json.180; let Json.178 : I32 = 34i64; let Json.177 : U8 = CallByName Num.123 Json.178; - let Json.175 : List U8 = CallByName List.4 Json.83 Json.177; - let Json.176 : List U8 = CallByName Str.12 Json.85; - let Json.172 : List U8 = CallByName List.8 Json.175 Json.176; - let Json.174 : I32 = 34i64; - let Json.173 : U8 = CallByName Num.123 Json.174; - let Json.169 : List U8 = CallByName List.4 Json.172 Json.173; - let Json.171 : I32 = 58i64; - let Json.170 : U8 = CallByName Num.123 Json.171; - let Json.167 : List U8 = CallByName List.4 Json.169 Json.170; - let Json.168 : {} = Struct {}; - let Json.87 : List U8 = CallByName Encode.23 Json.167 Json.86 Json.168; - joinpoint Json.162 Json.88: - let Json.160 : U64 = 1i64; - let Json.159 : U64 = CallByName Num.20 Json.84 Json.160; - let Json.158 : {List U8, U64} = Struct {Json.88, Json.159}; - ret Json.158; + let Json.173 : List U8 = CallByName List.4 Json.176 Json.177; + let Json.175 : I32 = 58i64; + let Json.174 : U8 = CallByName Num.123 Json.175; + let Json.171 : List U8 = CallByName List.4 Json.173 Json.174; + let Json.172 : {} = Struct {}; + let Json.91 : List U8 = CallByName Encode.23 Json.171 Json.90 Json.172; + joinpoint Json.166 Json.92: + let Json.164 : U64 = 1i64; + let Json.163 : U64 = CallByName Num.20 Json.88 Json.164; + let Json.162 : {List U8, U64} = Struct {Json.92, Json.163}; + ret Json.162; in - let Json.166 : U64 = 0i64; - let Json.163 : Int1 = CallByName Num.24 Json.84 Json.166; - if Json.163 then - let Json.165 : I32 = 44i64; - let Json.164 : U8 = CallByName Num.123 Json.165; - let Json.161 : List U8 = CallByName List.4 Json.87 Json.164; - jump Json.162 Json.161; + let Json.170 : U64 = 1i64; + let Json.167 : Int1 = CallByName Num.24 Json.88 Json.170; + if Json.167 then + let Json.169 : I32 = 44i64; + let Json.168 : U8 = CallByName Num.123 Json.169; + let Json.165 : List U8 = CallByName List.4 Json.91 Json.168; + jump Json.166 Json.165; else - jump Json.162 Json.87; + jump Json.166 Json.91; procedure List.122 (List.123, List.124, #Attr.12): let List.121 : {} = StructAtIndex 0 #Attr.12; - let List.344 : {List U8, U64} = CallByName Json.79 List.123 List.124; + let List.344 : {List U8, U64} = CallByName Json.83 List.123 List.124; let List.343 : [C [], C {List U8, U64}] = TagId(1) List.344; ret List.343; procedure List.122 (List.123, List.124, #Attr.12): let List.121 : {} = StructAtIndex 0 #Attr.12; - let List.425 : {List U8, U64} = CallByName Json.79 List.123 List.124; + let List.425 : {List U8, U64} = CallByName Json.83 List.123 List.124; let List.424 : [C [], C {List U8, U64}] = TagId(1) List.425; ret List.424; @@ -320,7 +320,7 @@ procedure List.66 (#Attr.2, #Attr.3): let List.405 : List U8 = lowlevel ListAppendUnsafe #Attr.2 #Attr.3; ret List.405; -procedure List.77 (List.361, List.362, List.363, List.364, List.365): +procedure List.77 (List.358, List.359, List.360, List.361, List.362): joinpoint List.330 List.286 List.287 List.288 List.289 List.290: let List.332 : Int1 = CallByName Num.22 List.289 List.290; if List.332 then @@ -345,9 +345,9 @@ procedure List.77 (List.361, List.362, List.363, List.364, List.365): let List.331 : [C [], C {List U8, U64}] = TagId(1) List.287; ret List.331; in - jump List.330 List.361 List.362 List.363 List.364 List.365; + jump List.330 List.358 List.359 List.360 List.361 List.362; -procedure List.77 (List.442, List.443, List.444, List.445, List.446): +procedure List.77 (List.439, List.440, List.441, List.442, List.443): joinpoint List.411 List.286 List.287 List.288 List.289 List.290: let List.413 : Int1 = CallByName Num.22 List.289 List.290; if List.413 then @@ -372,7 +372,7 @@ procedure List.77 (List.442, List.443, List.444, List.445, List.446): let List.412 : [C [], C {List U8, U64}] = TagId(1) List.287; ret List.412; in - jump List.411 List.442 List.443 List.444 List.445 List.446; + jump List.411 List.439 List.440 List.441 List.442 List.443; procedure List.8 (#Attr.2, #Attr.3): let List.403 : List U8 = lowlevel ListConcat #Attr.2 #Attr.3; diff --git a/crates/compiler/test_mono/generated/encode_derived_record_one_field_string.txt b/crates/compiler/test_mono/generated/encode_derived_record_one_field_string.txt index af9fddf50a..fa73e5a208 100644 --- a/crates/compiler/test_mono/generated/encode_derived_record_one_field_string.txt +++ b/crates/compiler/test_mono/generated/encode_derived_record_one_field_string.txt @@ -29,7 +29,7 @@ procedure Encode.23 (Encode.94, Encode.102, Encode.96): ret Encode.106; procedure Encode.23 (Encode.94, Encode.102, Encode.96): - let Encode.113 : List U8 = CallByName Json.77 Encode.94 Encode.96 Encode.102; + let Encode.113 : List U8 = CallByName Json.81 Encode.94 Encode.96 Encode.102; ret Encode.113; procedure Encode.23 (Encode.94, Encode.102, Encode.96): @@ -43,95 +43,95 @@ procedure Encode.25 (Encode.100, Encode.101): ret Encode.103; procedure Json.1 (): - let Json.102 : {} = Struct {}; - ret Json.102; - -procedure Json.17 (Json.64): - let Json.107 : {Str} = Struct {Json.64}; - let Json.106 : {Str} = CallByName Encode.22 Json.107; + let Json.106 : {} = Struct {}; ret Json.106; -procedure Json.19 (Json.76): - let Json.104 : {List {Str, {Str}}} = Struct {Json.76}; - let Json.103 : {List {Str, {Str}}} = CallByName Encode.22 Json.104; - ret Json.103; +procedure Json.17 (Json.64): + let Json.111 : {Str} = Struct {Json.64}; + let Json.110 : {Str} = CallByName Encode.22 Json.111; + ret Json.110; -procedure Json.65 (Json.66, Json.108, #Attr.12): +procedure Json.19 (Json.80): + let Json.108 : {List {Str, {Str}}} = Struct {Json.80}; + let Json.107 : {List {Str, {Str}}} = CallByName Encode.22 Json.108; + ret Json.107; + +procedure Json.65 (Json.66, Json.112, #Attr.12): let Json.64 : Str = StructAtIndex 0 #Attr.12; inc Json.64; dec #Attr.12; + let Json.154 : I32 = 34i64; + let Json.153 : U8 = CallByName Num.123 Json.154; + let Json.151 : List U8 = CallByName List.4 Json.66 Json.153; + let Json.152 : List U8 = CallByName Str.12 Json.64; + let Json.148 : List U8 = CallByName List.8 Json.151 Json.152; let Json.150 : I32 = 34i64; let Json.149 : U8 = CallByName Num.123 Json.150; - let Json.147 : List U8 = CallByName List.4 Json.66 Json.149; - let Json.148 : List U8 = CallByName Str.12 Json.64; - let Json.144 : List U8 = CallByName List.8 Json.147 Json.148; - let Json.146 : I32 = 34i64; - let Json.145 : U8 = CallByName Num.123 Json.146; - let Json.143 : List U8 = CallByName List.4 Json.144 Json.145; - ret Json.143; + let Json.147 : List U8 = CallByName List.4 Json.148 Json.149; + ret Json.147; -procedure Json.77 (Json.78, Json.105, #Attr.12): - let Json.76 : List {Str, {Str}} = StructAtIndex 0 #Attr.12; - inc Json.76; +procedure Json.81 (Json.82, Json.109, #Attr.12): + let Json.80 : List {Str, {Str}} = StructAtIndex 0 #Attr.12; + inc Json.80; dec #Attr.12; - let Json.141 : I32 = 123i64; - let Json.140 : U8 = CallByName Num.123 Json.141; - let Json.80 : List U8 = CallByName List.4 Json.78 Json.140; - let Json.139 : U64 = CallByName List.6 Json.76; - let Json.116 : {List U8, U64} = Struct {Json.80, Json.139}; - let Json.117 : {} = Struct {}; - let Json.115 : {List U8, U64} = CallByName List.18 Json.76 Json.116 Json.117; - dec Json.76; - let Json.82 : List U8 = StructAtIndex 0 Json.115; - inc Json.82; - dec Json.115; - let Json.114 : I32 = 125i64; - let Json.113 : U8 = CallByName Num.123 Json.114; - let Json.112 : List U8 = CallByName List.4 Json.82 Json.113; - ret Json.112; - -procedure Json.79 (Json.110, Json.111): - let Json.85 : Str = StructAtIndex 0 Json.111; - inc Json.85; - let Json.86 : {Str} = StructAtIndex 1 Json.111; + let Json.145 : I32 = 123i64; + let Json.144 : U8 = CallByName Num.123 Json.145; + let Json.84 : List U8 = CallByName List.4 Json.82 Json.144; + let Json.143 : U64 = CallByName List.6 Json.80; + let Json.120 : {List U8, U64} = Struct {Json.84, Json.143}; + let Json.121 : {} = Struct {}; + let Json.119 : {List U8, U64} = CallByName List.18 Json.80 Json.120 Json.121; + dec Json.80; + let Json.86 : List U8 = StructAtIndex 0 Json.119; inc Json.86; - dec Json.111; - let Json.83 : List U8 = StructAtIndex 0 Json.110; - inc Json.83; - let Json.84 : U64 = StructAtIndex 1 Json.110; - dec Json.110; + dec Json.119; + let Json.118 : I32 = 125i64; + let Json.117 : U8 = CallByName Num.123 Json.118; + let Json.116 : List U8 = CallByName List.4 Json.86 Json.117; + ret Json.116; + +procedure Json.83 (Json.114, Json.115): + let Json.89 : Str = StructAtIndex 0 Json.115; + inc Json.89; + let Json.90 : {Str} = StructAtIndex 1 Json.115; + inc Json.90; + dec Json.115; + let Json.87 : List U8 = StructAtIndex 0 Json.114; + inc Json.87; + let Json.88 : U64 = StructAtIndex 1 Json.114; + dec Json.114; + let Json.142 : I32 = 34i64; + let Json.141 : U8 = CallByName Num.123 Json.142; + let Json.139 : List U8 = CallByName List.4 Json.87 Json.141; + let Json.140 : List U8 = CallByName Str.12 Json.89; + let Json.136 : List U8 = CallByName List.8 Json.139 Json.140; let Json.138 : I32 = 34i64; let Json.137 : U8 = CallByName Num.123 Json.138; - let Json.135 : List U8 = CallByName List.4 Json.83 Json.137; - let Json.136 : List U8 = CallByName Str.12 Json.85; - let Json.132 : List U8 = CallByName List.8 Json.135 Json.136; - let Json.134 : I32 = 34i64; - let Json.133 : U8 = CallByName Num.123 Json.134; - let Json.129 : List U8 = CallByName List.4 Json.132 Json.133; - let Json.131 : I32 = 58i64; - let Json.130 : U8 = CallByName Num.123 Json.131; - let Json.127 : List U8 = CallByName List.4 Json.129 Json.130; - let Json.128 : {} = Struct {}; - let Json.87 : List U8 = CallByName Encode.23 Json.127 Json.86 Json.128; - joinpoint Json.122 Json.88: - let Json.120 : U64 = 1i64; - let Json.119 : U64 = CallByName Num.20 Json.84 Json.120; - let Json.118 : {List U8, U64} = Struct {Json.88, Json.119}; - ret Json.118; + let Json.133 : List U8 = CallByName List.4 Json.136 Json.137; + let Json.135 : I32 = 58i64; + let Json.134 : U8 = CallByName Num.123 Json.135; + let Json.131 : List U8 = CallByName List.4 Json.133 Json.134; + let Json.132 : {} = Struct {}; + let Json.91 : List U8 = CallByName Encode.23 Json.131 Json.90 Json.132; + joinpoint Json.126 Json.92: + let Json.124 : U64 = 1i64; + let Json.123 : U64 = CallByName Num.20 Json.88 Json.124; + let Json.122 : {List U8, U64} = Struct {Json.92, Json.123}; + ret Json.122; in - let Json.126 : U64 = 0i64; - let Json.123 : Int1 = CallByName Num.24 Json.84 Json.126; - if Json.123 then - let Json.125 : I32 = 44i64; - let Json.124 : U8 = CallByName Num.123 Json.125; - let Json.121 : List U8 = CallByName List.4 Json.87 Json.124; - jump Json.122 Json.121; + let Json.130 : U64 = 1i64; + let Json.127 : Int1 = CallByName Num.24 Json.88 Json.130; + if Json.127 then + let Json.129 : I32 = 44i64; + let Json.128 : U8 = CallByName Num.123 Json.129; + let Json.125 : List U8 = CallByName List.4 Json.91 Json.128; + jump Json.126 Json.125; else - jump Json.122 Json.87; + jump Json.126 Json.91; procedure List.122 (List.123, List.124, #Attr.12): let List.121 : {} = StructAtIndex 0 #Attr.12; - let List.351 : {List U8, U64} = CallByName Json.79 List.123 List.124; + let List.351 : {List U8, U64} = CallByName Json.83 List.123 List.124; let List.350 : [C [], C {List U8, U64}] = TagId(1) List.351; ret List.350; @@ -188,7 +188,7 @@ procedure List.66 (#Attr.2, #Attr.3): let List.331 : List U8 = lowlevel ListAppendUnsafe #Attr.2 #Attr.3; ret List.331; -procedure List.77 (List.368, List.369, List.370, List.371, List.372): +procedure List.77 (List.365, List.366, List.367, List.368, List.369): joinpoint List.337 List.286 List.287 List.288 List.289 List.290: let List.339 : Int1 = CallByName Num.22 List.289 List.290; if List.339 then @@ -213,7 +213,7 @@ procedure List.77 (List.368, List.369, List.370, List.371, List.372): let List.338 : [C [], C {List U8, U64}] = TagId(1) List.287; ret List.338; in - jump List.337 List.368 List.369 List.370 List.371 List.372; + jump List.337 List.365 List.366 List.367 List.368 List.369; procedure List.8 (#Attr.2, #Attr.3): let List.329 : List U8 = lowlevel ListConcat #Attr.2 #Attr.3; diff --git a/crates/compiler/test_mono/generated/encode_derived_record_two_field_strings.txt b/crates/compiler/test_mono/generated/encode_derived_record_two_field_strings.txt index b27d827bd9..f7c65c3b08 100644 --- a/crates/compiler/test_mono/generated/encode_derived_record_two_field_strings.txt +++ b/crates/compiler/test_mono/generated/encode_derived_record_two_field_strings.txt @@ -37,7 +37,7 @@ procedure Encode.23 (Encode.94, Encode.102, Encode.96): ret Encode.106; procedure Encode.23 (Encode.94, Encode.102, Encode.96): - let Encode.113 : List U8 = CallByName Json.77 Encode.94 Encode.96 Encode.102; + let Encode.113 : List U8 = CallByName Json.81 Encode.94 Encode.96 Encode.102; ret Encode.113; procedure Encode.23 (Encode.94, Encode.102, Encode.96): @@ -51,95 +51,95 @@ procedure Encode.25 (Encode.100, Encode.101): ret Encode.103; procedure Json.1 (): - let Json.102 : {} = Struct {}; - ret Json.102; + let Json.106 : {} = Struct {}; + ret Json.106; procedure Json.17 (Json.64): - let Json.110 : {Str} = Struct {Json.64}; - let Json.109 : {Str} = CallByName Encode.22 Json.110; - ret Json.109; + let Json.114 : {Str} = Struct {Json.64}; + let Json.113 : {Str} = CallByName Encode.22 Json.114; + ret Json.113; -procedure Json.19 (Json.76): - let Json.104 : {List {Str, {Str}}} = Struct {Json.76}; - let Json.103 : {List {Str, {Str}}} = CallByName Encode.22 Json.104; - ret Json.103; +procedure Json.19 (Json.80): + let Json.108 : {List {Str, {Str}}} = Struct {Json.80}; + let Json.107 : {List {Str, {Str}}} = CallByName Encode.22 Json.108; + ret Json.107; -procedure Json.65 (Json.66, Json.108, #Attr.12): +procedure Json.65 (Json.66, Json.112, #Attr.12): let Json.64 : Str = StructAtIndex 0 #Attr.12; inc Json.64; dec #Attr.12; + let Json.157 : I32 = 34i64; + let Json.156 : U8 = CallByName Num.123 Json.157; + let Json.154 : List U8 = CallByName List.4 Json.66 Json.156; + let Json.155 : List U8 = CallByName Str.12 Json.64; + let Json.151 : List U8 = CallByName List.8 Json.154 Json.155; let Json.153 : I32 = 34i64; let Json.152 : U8 = CallByName Num.123 Json.153; - let Json.150 : List U8 = CallByName List.4 Json.66 Json.152; - let Json.151 : List U8 = CallByName Str.12 Json.64; - let Json.147 : List U8 = CallByName List.8 Json.150 Json.151; - let Json.149 : I32 = 34i64; - let Json.148 : U8 = CallByName Num.123 Json.149; - let Json.146 : List U8 = CallByName List.4 Json.147 Json.148; - ret Json.146; + let Json.150 : List U8 = CallByName List.4 Json.151 Json.152; + ret Json.150; -procedure Json.77 (Json.78, Json.105, #Attr.12): - let Json.76 : List {Str, {Str}} = StructAtIndex 0 #Attr.12; - inc Json.76; +procedure Json.81 (Json.82, Json.109, #Attr.12): + let Json.80 : List {Str, {Str}} = StructAtIndex 0 #Attr.12; + inc Json.80; dec #Attr.12; - let Json.144 : I32 = 123i64; - let Json.143 : U8 = CallByName Num.123 Json.144; - let Json.80 : List U8 = CallByName List.4 Json.78 Json.143; - let Json.142 : U64 = CallByName List.6 Json.76; - let Json.119 : {List U8, U64} = Struct {Json.80, Json.142}; - let Json.120 : {} = Struct {}; - let Json.118 : {List U8, U64} = CallByName List.18 Json.76 Json.119 Json.120; - dec Json.76; - let Json.82 : List U8 = StructAtIndex 0 Json.118; - inc Json.82; - dec Json.118; - let Json.117 : I32 = 125i64; - let Json.116 : U8 = CallByName Num.123 Json.117; - let Json.115 : List U8 = CallByName List.4 Json.82 Json.116; - ret Json.115; - -procedure Json.79 (Json.113, Json.114): - let Json.85 : Str = StructAtIndex 0 Json.114; - inc Json.85; - let Json.86 : {Str} = StructAtIndex 1 Json.114; + let Json.148 : I32 = 123i64; + let Json.147 : U8 = CallByName Num.123 Json.148; + let Json.84 : List U8 = CallByName List.4 Json.82 Json.147; + let Json.146 : U64 = CallByName List.6 Json.80; + let Json.123 : {List U8, U64} = Struct {Json.84, Json.146}; + let Json.124 : {} = Struct {}; + let Json.122 : {List U8, U64} = CallByName List.18 Json.80 Json.123 Json.124; + dec Json.80; + let Json.86 : List U8 = StructAtIndex 0 Json.122; inc Json.86; - dec Json.114; - let Json.83 : List U8 = StructAtIndex 0 Json.113; - inc Json.83; - let Json.84 : U64 = StructAtIndex 1 Json.113; - dec Json.113; + dec Json.122; + let Json.121 : I32 = 125i64; + let Json.120 : U8 = CallByName Num.123 Json.121; + let Json.119 : List U8 = CallByName List.4 Json.86 Json.120; + ret Json.119; + +procedure Json.83 (Json.117, Json.118): + let Json.89 : Str = StructAtIndex 0 Json.118; + inc Json.89; + let Json.90 : {Str} = StructAtIndex 1 Json.118; + inc Json.90; + dec Json.118; + let Json.87 : List U8 = StructAtIndex 0 Json.117; + inc Json.87; + let Json.88 : U64 = StructAtIndex 1 Json.117; + dec Json.117; + let Json.145 : I32 = 34i64; + let Json.144 : U8 = CallByName Num.123 Json.145; + let Json.142 : List U8 = CallByName List.4 Json.87 Json.144; + let Json.143 : List U8 = CallByName Str.12 Json.89; + let Json.139 : List U8 = CallByName List.8 Json.142 Json.143; let Json.141 : I32 = 34i64; let Json.140 : U8 = CallByName Num.123 Json.141; - let Json.138 : List U8 = CallByName List.4 Json.83 Json.140; - let Json.139 : List U8 = CallByName Str.12 Json.85; - let Json.135 : List U8 = CallByName List.8 Json.138 Json.139; - let Json.137 : I32 = 34i64; - let Json.136 : U8 = CallByName Num.123 Json.137; - let Json.132 : List U8 = CallByName List.4 Json.135 Json.136; - let Json.134 : I32 = 58i64; - let Json.133 : U8 = CallByName Num.123 Json.134; - let Json.130 : List U8 = CallByName List.4 Json.132 Json.133; - let Json.131 : {} = Struct {}; - let Json.87 : List U8 = CallByName Encode.23 Json.130 Json.86 Json.131; - joinpoint Json.125 Json.88: - let Json.123 : U64 = 1i64; - let Json.122 : U64 = CallByName Num.20 Json.84 Json.123; - let Json.121 : {List U8, U64} = Struct {Json.88, Json.122}; - ret Json.121; + let Json.136 : List U8 = CallByName List.4 Json.139 Json.140; + let Json.138 : I32 = 58i64; + let Json.137 : U8 = CallByName Num.123 Json.138; + let Json.134 : List U8 = CallByName List.4 Json.136 Json.137; + let Json.135 : {} = Struct {}; + let Json.91 : List U8 = CallByName Encode.23 Json.134 Json.90 Json.135; + joinpoint Json.129 Json.92: + let Json.127 : U64 = 1i64; + let Json.126 : U64 = CallByName Num.20 Json.88 Json.127; + let Json.125 : {List U8, U64} = Struct {Json.92, Json.126}; + ret Json.125; in - let Json.129 : U64 = 0i64; - let Json.126 : Int1 = CallByName Num.24 Json.84 Json.129; - if Json.126 then - let Json.128 : I32 = 44i64; - let Json.127 : U8 = CallByName Num.123 Json.128; - let Json.124 : List U8 = CallByName List.4 Json.87 Json.127; - jump Json.125 Json.124; + let Json.133 : U64 = 1i64; + let Json.130 : Int1 = CallByName Num.24 Json.88 Json.133; + if Json.130 then + let Json.132 : I32 = 44i64; + let Json.131 : U8 = CallByName Num.123 Json.132; + let Json.128 : List U8 = CallByName List.4 Json.91 Json.131; + jump Json.129 Json.128; else - jump Json.125 Json.87; + jump Json.129 Json.91; procedure List.122 (List.123, List.124, #Attr.12): let List.121 : {} = StructAtIndex 0 #Attr.12; - let List.351 : {List U8, U64} = CallByName Json.79 List.123 List.124; + let List.351 : {List U8, U64} = CallByName Json.83 List.123 List.124; let List.350 : [C [], C {List U8, U64}] = TagId(1) List.351; ret List.350; @@ -196,7 +196,7 @@ procedure List.66 (#Attr.2, #Attr.3): let List.331 : List U8 = lowlevel ListAppendUnsafe #Attr.2 #Attr.3; ret List.331; -procedure List.77 (List.368, List.369, List.370, List.371, List.372): +procedure List.77 (List.365, List.366, List.367, List.368, List.369): joinpoint List.337 List.286 List.287 List.288 List.289 List.290: let List.339 : Int1 = CallByName Num.22 List.289 List.290; if List.339 then @@ -221,7 +221,7 @@ procedure List.77 (List.368, List.369, List.370, List.371, List.372): let List.338 : [C [], C {List U8, U64}] = TagId(1) List.287; ret List.338; in - jump List.337 List.368 List.369 List.370 List.371 List.372; + jump List.337 List.365 List.366 List.367 List.368 List.369; procedure List.8 (#Attr.2, #Attr.3): let List.329 : List U8 = lowlevel ListConcat #Attr.2 #Attr.3; diff --git a/crates/compiler/test_mono/generated/encode_derived_string.txt b/crates/compiler/test_mono/generated/encode_derived_string.txt index c3d27bbbf8..bbc03273b7 100644 --- a/crates/compiler/test_mono/generated/encode_derived_string.txt +++ b/crates/compiler/test_mono/generated/encode_derived_string.txt @@ -12,27 +12,27 @@ procedure Encode.25 (Encode.100, Encode.101): ret Encode.103; procedure Json.1 (): - let Json.102 : {} = Struct {}; - ret Json.102; + let Json.106 : {} = Struct {}; + ret Json.106; procedure Json.17 (Json.64): - let Json.104 : {Str} = Struct {Json.64}; - let Json.103 : {Str} = CallByName Encode.22 Json.104; - ret Json.103; + let Json.108 : {Str} = Struct {Json.64}; + let Json.107 : {Str} = CallByName Encode.22 Json.108; + ret Json.107; -procedure Json.65 (Json.66, Json.105, #Attr.12): +procedure Json.65 (Json.66, Json.109, #Attr.12): let Json.64 : Str = StructAtIndex 0 #Attr.12; inc Json.64; dec #Attr.12; + let Json.118 : I32 = 34i64; + let Json.117 : U8 = CallByName Num.123 Json.118; + let Json.115 : List U8 = CallByName List.4 Json.66 Json.117; + let Json.116 : List U8 = CallByName Str.12 Json.64; + let Json.112 : List U8 = CallByName List.8 Json.115 Json.116; let Json.114 : I32 = 34i64; let Json.113 : U8 = CallByName Num.123 Json.114; - let Json.111 : List U8 = CallByName List.4 Json.66 Json.113; - let Json.112 : List U8 = CallByName Str.12 Json.64; - let Json.108 : List U8 = CallByName List.8 Json.111 Json.112; - let Json.110 : I32 = 34i64; - let Json.109 : U8 = CallByName Num.123 Json.110; - let Json.107 : List U8 = CallByName List.4 Json.108 Json.109; - ret Json.107; + let Json.111 : List U8 = CallByName List.4 Json.112 Json.113; + ret Json.111; procedure List.4 (List.90, List.91): let List.302 : U64 = 1i64; diff --git a/crates/compiler/test_mono/generated/encode_derived_tag_one_field_string.txt b/crates/compiler/test_mono/generated/encode_derived_tag_one_field_string.txt index 031b27f0e9..2e0790f4e9 100644 --- a/crates/compiler/test_mono/generated/encode_derived_tag_one_field_string.txt +++ b/crates/compiler/test_mono/generated/encode_derived_tag_one_field_string.txt @@ -31,7 +31,7 @@ procedure Encode.23 (Encode.94, Encode.102, Encode.96): ret Encode.106; procedure Encode.23 (Encode.94, Encode.102, Encode.96): - let Encode.113 : List U8 = CallByName Json.91 Encode.94 Encode.96 Encode.102; + let Encode.113 : List U8 = CallByName Json.95 Encode.94 Encode.96 Encode.102; ret Encode.113; procedure Encode.23 (Encode.94, Encode.102, Encode.96): @@ -45,98 +45,98 @@ procedure Encode.25 (Encode.100, Encode.101): ret Encode.103; procedure Json.1 (): - let Json.102 : {} = Struct {}; - ret Json.102; - -procedure Json.17 (Json.64): - let Json.107 : {Str} = Struct {Json.64}; - let Json.106 : {Str} = CallByName Encode.22 Json.107; + let Json.106 : {} = Struct {}; ret Json.106; -procedure Json.20 (Json.89, Json.90): - let Json.104 : {Str, List {Str}} = Struct {Json.89, Json.90}; - let Json.103 : {Str, List {Str}} = CallByName Encode.22 Json.104; - ret Json.103; +procedure Json.17 (Json.64): + let Json.111 : {Str} = Struct {Json.64}; + let Json.110 : {Str} = CallByName Encode.22 Json.111; + ret Json.110; -procedure Json.65 (Json.66, Json.108, #Attr.12): +procedure Json.20 (Json.93, Json.94): + let Json.108 : {Str, List {Str}} = Struct {Json.93, Json.94}; + let Json.107 : {Str, List {Str}} = CallByName Encode.22 Json.108; + ret Json.107; + +procedure Json.65 (Json.66, Json.112, #Attr.12): let Json.64 : Str = StructAtIndex 0 #Attr.12; inc Json.64; dec #Attr.12; + let Json.159 : I32 = 34i64; + let Json.158 : U8 = CallByName Num.123 Json.159; + let Json.156 : List U8 = CallByName List.4 Json.66 Json.158; + let Json.157 : List U8 = CallByName Str.12 Json.64; + let Json.153 : List U8 = CallByName List.8 Json.156 Json.157; let Json.155 : I32 = 34i64; let Json.154 : U8 = CallByName Num.123 Json.155; - let Json.152 : List U8 = CallByName List.4 Json.66 Json.154; - let Json.153 : List U8 = CallByName Str.12 Json.64; - let Json.149 : List U8 = CallByName List.8 Json.152 Json.153; - let Json.151 : I32 = 34i64; - let Json.150 : U8 = CallByName Num.123 Json.151; - let Json.148 : List U8 = CallByName List.4 Json.149 Json.150; - ret Json.148; + let Json.152 : List U8 = CallByName List.4 Json.153 Json.154; + ret Json.152; -procedure Json.91 (Json.92, Json.105, #Attr.12): - let Json.90 : List {Str} = StructAtIndex 1 #Attr.12; - inc Json.90; - let Json.89 : Str = StructAtIndex 0 #Attr.12; - inc Json.89; +procedure Json.95 (Json.96, Json.109, #Attr.12): + let Json.94 : List {Str} = StructAtIndex 1 #Attr.12; + inc Json.94; + let Json.93 : Str = StructAtIndex 0 #Attr.12; + inc Json.93; dec #Attr.12; - let Json.146 : I32 = 123i64; - let Json.145 : U8 = CallByName Num.123 Json.146; - let Json.142 : List U8 = CallByName List.4 Json.92 Json.145; - let Json.144 : I32 = 34i64; - let Json.143 : U8 = CallByName Num.123 Json.144; - let Json.140 : List U8 = CallByName List.4 Json.142 Json.143; - let Json.141 : List U8 = CallByName Str.12 Json.89; - let Json.137 : List U8 = CallByName List.8 Json.140 Json.141; - let Json.139 : I32 = 34i64; - let Json.138 : U8 = CallByName Num.123 Json.139; - let Json.134 : List U8 = CallByName List.4 Json.137 Json.138; - let Json.136 : I32 = 58i64; - let Json.135 : U8 = CallByName Num.123 Json.136; - let Json.131 : List U8 = CallByName List.4 Json.134 Json.135; - let Json.133 : I32 = 91i64; - let Json.132 : U8 = CallByName Num.123 Json.133; - let Json.94 : List U8 = CallByName List.4 Json.131 Json.132; - let Json.130 : U64 = CallByName List.6 Json.90; - let Json.118 : {List U8, U64} = Struct {Json.94, Json.130}; - let Json.119 : {} = Struct {}; - let Json.117 : {List U8, U64} = CallByName List.18 Json.90 Json.118 Json.119; - dec Json.90; - let Json.96 : List U8 = StructAtIndex 0 Json.117; - inc Json.96; - dec Json.117; - let Json.116 : I32 = 93i64; - let Json.115 : U8 = CallByName Num.123 Json.116; - let Json.112 : List U8 = CallByName List.4 Json.96 Json.115; - let Json.114 : I32 = 125i64; - let Json.113 : U8 = CallByName Num.123 Json.114; - let Json.111 : List U8 = CallByName List.4 Json.112 Json.113; - ret Json.111; + let Json.150 : I32 = 123i64; + let Json.149 : U8 = CallByName Num.123 Json.150; + let Json.146 : List U8 = CallByName List.4 Json.96 Json.149; + let Json.148 : I32 = 34i64; + let Json.147 : U8 = CallByName Num.123 Json.148; + let Json.144 : List U8 = CallByName List.4 Json.146 Json.147; + let Json.145 : List U8 = CallByName Str.12 Json.93; + let Json.141 : List U8 = CallByName List.8 Json.144 Json.145; + let Json.143 : I32 = 34i64; + let Json.142 : U8 = CallByName Num.123 Json.143; + let Json.138 : List U8 = CallByName List.4 Json.141 Json.142; + let Json.140 : I32 = 58i64; + let Json.139 : U8 = CallByName Num.123 Json.140; + let Json.135 : List U8 = CallByName List.4 Json.138 Json.139; + let Json.137 : I32 = 91i64; + let Json.136 : U8 = CallByName Num.123 Json.137; + let Json.98 : List U8 = CallByName List.4 Json.135 Json.136; + let Json.134 : U64 = CallByName List.6 Json.94; + let Json.122 : {List U8, U64} = Struct {Json.98, Json.134}; + let Json.123 : {} = Struct {}; + let Json.121 : {List U8, U64} = CallByName List.18 Json.94 Json.122 Json.123; + dec Json.94; + let Json.100 : List U8 = StructAtIndex 0 Json.121; + inc Json.100; + dec Json.121; + let Json.120 : I32 = 93i64; + let Json.119 : U8 = CallByName Num.123 Json.120; + let Json.116 : List U8 = CallByName List.4 Json.100 Json.119; + let Json.118 : I32 = 125i64; + let Json.117 : U8 = CallByName Num.123 Json.118; + let Json.115 : List U8 = CallByName List.4 Json.116 Json.117; + ret Json.115; -procedure Json.93 (Json.110, Json.99): - let Json.97 : List U8 = StructAtIndex 0 Json.110; - inc Json.97; - let Json.98 : U64 = StructAtIndex 1 Json.110; - dec Json.110; - let Json.129 : {} = Struct {}; - let Json.100 : List U8 = CallByName Encode.23 Json.97 Json.99 Json.129; - joinpoint Json.124 Json.101: - let Json.122 : U64 = 1i64; - let Json.121 : U64 = CallByName Num.20 Json.98 Json.122; - let Json.120 : {List U8, U64} = Struct {Json.101, Json.121}; - ret Json.120; +procedure Json.97 (Json.114, Json.103): + let Json.101 : List U8 = StructAtIndex 0 Json.114; + inc Json.101; + let Json.102 : U64 = StructAtIndex 1 Json.114; + dec Json.114; + let Json.133 : {} = Struct {}; + let Json.104 : List U8 = CallByName Encode.23 Json.101 Json.103 Json.133; + joinpoint Json.128 Json.105: + let Json.126 : U64 = 1i64; + let Json.125 : U64 = CallByName Num.20 Json.102 Json.126; + let Json.124 : {List U8, U64} = Struct {Json.105, Json.125}; + ret Json.124; in - let Json.128 : U64 = 0i64; - let Json.125 : Int1 = CallByName Num.24 Json.98 Json.128; - if Json.125 then - let Json.127 : I32 = 44i64; - let Json.126 : U8 = CallByName Num.123 Json.127; - let Json.123 : List U8 = CallByName List.4 Json.100 Json.126; - jump Json.124 Json.123; + let Json.132 : U64 = 1i64; + let Json.129 : Int1 = CallByName Num.24 Json.102 Json.132; + if Json.129 then + let Json.131 : I32 = 44i64; + let Json.130 : U8 = CallByName Num.123 Json.131; + let Json.127 : List U8 = CallByName List.4 Json.104 Json.130; + jump Json.128 Json.127; else - jump Json.124 Json.100; + jump Json.128 Json.104; procedure List.122 (List.123, List.124, #Attr.12): let List.121 : {} = StructAtIndex 0 #Attr.12; - let List.357 : {List U8, U64} = CallByName Json.93 List.123 List.124; + let List.357 : {List U8, U64} = CallByName Json.97 List.123 List.124; let List.356 : [C [], C {List U8, U64}] = TagId(1) List.357; ret List.356; @@ -193,7 +193,7 @@ procedure List.66 (#Attr.2, #Attr.3): let List.337 : List U8 = lowlevel ListAppendUnsafe #Attr.2 #Attr.3; ret List.337; -procedure List.77 (List.374, List.375, List.376, List.377, List.378): +procedure List.77 (List.371, List.372, List.373, List.374, List.375): joinpoint List.343 List.286 List.287 List.288 List.289 List.290: let List.345 : Int1 = CallByName Num.22 List.289 List.290; if List.345 then @@ -218,7 +218,7 @@ procedure List.77 (List.374, List.375, List.376, List.377, List.378): let List.344 : [C [], C {List U8, U64}] = TagId(1) List.287; ret List.344; in - jump List.343 List.374 List.375 List.376 List.377 List.378; + jump List.343 List.371 List.372 List.373 List.374 List.375; procedure List.8 (#Attr.2, #Attr.3): let List.336 : List U8 = lowlevel ListConcat #Attr.2 #Attr.3; diff --git a/crates/compiler/test_mono/generated/encode_derived_tag_two_payloads_string.txt b/crates/compiler/test_mono/generated/encode_derived_tag_two_payloads_string.txt index 10098c3120..54eb3ba90a 100644 --- a/crates/compiler/test_mono/generated/encode_derived_tag_two_payloads_string.txt +++ b/crates/compiler/test_mono/generated/encode_derived_tag_two_payloads_string.txt @@ -37,7 +37,7 @@ procedure Encode.23 (Encode.94, Encode.102, Encode.96): ret Encode.106; procedure Encode.23 (Encode.94, Encode.102, Encode.96): - let Encode.113 : List U8 = CallByName Json.91 Encode.94 Encode.96 Encode.102; + let Encode.113 : List U8 = CallByName Json.95 Encode.94 Encode.96 Encode.102; ret Encode.113; procedure Encode.23 (Encode.94, Encode.102, Encode.96): @@ -51,98 +51,98 @@ procedure Encode.25 (Encode.100, Encode.101): ret Encode.103; procedure Json.1 (): - let Json.102 : {} = Struct {}; - ret Json.102; + let Json.106 : {} = Struct {}; + ret Json.106; procedure Json.17 (Json.64): - let Json.110 : {Str} = Struct {Json.64}; - let Json.109 : {Str} = CallByName Encode.22 Json.110; - ret Json.109; + let Json.114 : {Str} = Struct {Json.64}; + let Json.113 : {Str} = CallByName Encode.22 Json.114; + ret Json.113; -procedure Json.20 (Json.89, Json.90): - let Json.104 : {Str, List {Str}} = Struct {Json.89, Json.90}; - let Json.103 : {Str, List {Str}} = CallByName Encode.22 Json.104; - ret Json.103; +procedure Json.20 (Json.93, Json.94): + let Json.108 : {Str, List {Str}} = Struct {Json.93, Json.94}; + let Json.107 : {Str, List {Str}} = CallByName Encode.22 Json.108; + ret Json.107; -procedure Json.65 (Json.66, Json.108, #Attr.12): +procedure Json.65 (Json.66, Json.112, #Attr.12): let Json.64 : Str = StructAtIndex 0 #Attr.12; inc Json.64; dec #Attr.12; + let Json.162 : I32 = 34i64; + let Json.161 : U8 = CallByName Num.123 Json.162; + let Json.159 : List U8 = CallByName List.4 Json.66 Json.161; + let Json.160 : List U8 = CallByName Str.12 Json.64; + let Json.156 : List U8 = CallByName List.8 Json.159 Json.160; let Json.158 : I32 = 34i64; let Json.157 : U8 = CallByName Num.123 Json.158; - let Json.155 : List U8 = CallByName List.4 Json.66 Json.157; - let Json.156 : List U8 = CallByName Str.12 Json.64; - let Json.152 : List U8 = CallByName List.8 Json.155 Json.156; - let Json.154 : I32 = 34i64; - let Json.153 : U8 = CallByName Num.123 Json.154; - let Json.151 : List U8 = CallByName List.4 Json.152 Json.153; - ret Json.151; + let Json.155 : List U8 = CallByName List.4 Json.156 Json.157; + ret Json.155; -procedure Json.91 (Json.92, Json.105, #Attr.12): - let Json.90 : List {Str} = StructAtIndex 1 #Attr.12; - inc Json.90; - let Json.89 : Str = StructAtIndex 0 #Attr.12; - inc Json.89; +procedure Json.95 (Json.96, Json.109, #Attr.12): + let Json.94 : List {Str} = StructAtIndex 1 #Attr.12; + inc Json.94; + let Json.93 : Str = StructAtIndex 0 #Attr.12; + inc Json.93; dec #Attr.12; - let Json.149 : I32 = 123i64; - let Json.148 : U8 = CallByName Num.123 Json.149; - let Json.145 : List U8 = CallByName List.4 Json.92 Json.148; - let Json.147 : I32 = 34i64; - let Json.146 : U8 = CallByName Num.123 Json.147; - let Json.143 : List U8 = CallByName List.4 Json.145 Json.146; - let Json.144 : List U8 = CallByName Str.12 Json.89; - let Json.140 : List U8 = CallByName List.8 Json.143 Json.144; - let Json.142 : I32 = 34i64; - let Json.141 : U8 = CallByName Num.123 Json.142; - let Json.137 : List U8 = CallByName List.4 Json.140 Json.141; - let Json.139 : I32 = 58i64; - let Json.138 : U8 = CallByName Num.123 Json.139; - let Json.134 : List U8 = CallByName List.4 Json.137 Json.138; - let Json.136 : I32 = 91i64; - let Json.135 : U8 = CallByName Num.123 Json.136; - let Json.94 : List U8 = CallByName List.4 Json.134 Json.135; - let Json.133 : U64 = CallByName List.6 Json.90; - let Json.121 : {List U8, U64} = Struct {Json.94, Json.133}; - let Json.122 : {} = Struct {}; - let Json.120 : {List U8, U64} = CallByName List.18 Json.90 Json.121 Json.122; - dec Json.90; - let Json.96 : List U8 = StructAtIndex 0 Json.120; - inc Json.96; - dec Json.120; - let Json.119 : I32 = 93i64; - let Json.118 : U8 = CallByName Num.123 Json.119; - let Json.115 : List U8 = CallByName List.4 Json.96 Json.118; - let Json.117 : I32 = 125i64; - let Json.116 : U8 = CallByName Num.123 Json.117; - let Json.114 : List U8 = CallByName List.4 Json.115 Json.116; - ret Json.114; + let Json.153 : I32 = 123i64; + let Json.152 : U8 = CallByName Num.123 Json.153; + let Json.149 : List U8 = CallByName List.4 Json.96 Json.152; + let Json.151 : I32 = 34i64; + let Json.150 : U8 = CallByName Num.123 Json.151; + let Json.147 : List U8 = CallByName List.4 Json.149 Json.150; + let Json.148 : List U8 = CallByName Str.12 Json.93; + let Json.144 : List U8 = CallByName List.8 Json.147 Json.148; + let Json.146 : I32 = 34i64; + let Json.145 : U8 = CallByName Num.123 Json.146; + let Json.141 : List U8 = CallByName List.4 Json.144 Json.145; + let Json.143 : I32 = 58i64; + let Json.142 : U8 = CallByName Num.123 Json.143; + let Json.138 : List U8 = CallByName List.4 Json.141 Json.142; + let Json.140 : I32 = 91i64; + let Json.139 : U8 = CallByName Num.123 Json.140; + let Json.98 : List U8 = CallByName List.4 Json.138 Json.139; + let Json.137 : U64 = CallByName List.6 Json.94; + let Json.125 : {List U8, U64} = Struct {Json.98, Json.137}; + let Json.126 : {} = Struct {}; + let Json.124 : {List U8, U64} = CallByName List.18 Json.94 Json.125 Json.126; + dec Json.94; + let Json.100 : List U8 = StructAtIndex 0 Json.124; + inc Json.100; + dec Json.124; + let Json.123 : I32 = 93i64; + let Json.122 : U8 = CallByName Num.123 Json.123; + let Json.119 : List U8 = CallByName List.4 Json.100 Json.122; + let Json.121 : I32 = 125i64; + let Json.120 : U8 = CallByName Num.123 Json.121; + let Json.118 : List U8 = CallByName List.4 Json.119 Json.120; + ret Json.118; -procedure Json.93 (Json.113, Json.99): - let Json.97 : List U8 = StructAtIndex 0 Json.113; - inc Json.97; - let Json.98 : U64 = StructAtIndex 1 Json.113; - dec Json.113; - let Json.132 : {} = Struct {}; - let Json.100 : List U8 = CallByName Encode.23 Json.97 Json.99 Json.132; - joinpoint Json.127 Json.101: - let Json.125 : U64 = 1i64; - let Json.124 : U64 = CallByName Num.20 Json.98 Json.125; - let Json.123 : {List U8, U64} = Struct {Json.101, Json.124}; - ret Json.123; +procedure Json.97 (Json.117, Json.103): + let Json.101 : List U8 = StructAtIndex 0 Json.117; + inc Json.101; + let Json.102 : U64 = StructAtIndex 1 Json.117; + dec Json.117; + let Json.136 : {} = Struct {}; + let Json.104 : List U8 = CallByName Encode.23 Json.101 Json.103 Json.136; + joinpoint Json.131 Json.105: + let Json.129 : U64 = 1i64; + let Json.128 : U64 = CallByName Num.20 Json.102 Json.129; + let Json.127 : {List U8, U64} = Struct {Json.105, Json.128}; + ret Json.127; in - let Json.131 : U64 = 0i64; - let Json.128 : Int1 = CallByName Num.24 Json.98 Json.131; - if Json.128 then - let Json.130 : I32 = 44i64; - let Json.129 : U8 = CallByName Num.123 Json.130; - let Json.126 : List U8 = CallByName List.4 Json.100 Json.129; - jump Json.127 Json.126; + let Json.135 : U64 = 1i64; + let Json.132 : Int1 = CallByName Num.24 Json.102 Json.135; + if Json.132 then + let Json.134 : I32 = 44i64; + let Json.133 : U8 = CallByName Num.123 Json.134; + let Json.130 : List U8 = CallByName List.4 Json.104 Json.133; + jump Json.131 Json.130; else - jump Json.127 Json.100; + jump Json.131 Json.104; procedure List.122 (List.123, List.124, #Attr.12): let List.121 : {} = StructAtIndex 0 #Attr.12; - let List.357 : {List U8, U64} = CallByName Json.93 List.123 List.124; + let List.357 : {List U8, U64} = CallByName Json.97 List.123 List.124; let List.356 : [C [], C {List U8, U64}] = TagId(1) List.357; ret List.356; @@ -199,7 +199,7 @@ procedure List.66 (#Attr.2, #Attr.3): let List.337 : List U8 = lowlevel ListAppendUnsafe #Attr.2 #Attr.3; ret List.337; -procedure List.77 (List.374, List.375, List.376, List.377, List.378): +procedure List.77 (List.371, List.372, List.373, List.374, List.375): joinpoint List.343 List.286 List.287 List.288 List.289 List.290: let List.345 : Int1 = CallByName Num.22 List.289 List.290; if List.345 then @@ -224,7 +224,7 @@ procedure List.77 (List.374, List.375, List.376, List.377, List.378): let List.344 : [C [], C {List U8, U64}] = TagId(1) List.287; ret List.344; in - jump List.343 List.374 List.375 List.376 List.377 List.378; + jump List.343 List.371 List.372 List.373 List.374 List.375; procedure List.8 (#Attr.2, #Attr.3): let List.336 : List U8 = lowlevel ListConcat #Attr.2 #Attr.3; diff --git a/crates/compiler/test_mono/generated/instantiate_annotated_as_recursive_alias_multiple_polymorphic_expr.txt b/crates/compiler/test_mono/generated/instantiate_annotated_as_recursive_alias_multiple_polymorphic_expr.txt index 1db0cfca3c..b8cef0df60 100644 --- a/crates/compiler/test_mono/generated/instantiate_annotated_as_recursive_alias_multiple_polymorphic_expr.txt +++ b/crates/compiler/test_mono/generated/instantiate_annotated_as_recursive_alias_multiple_polymorphic_expr.txt @@ -1,5 +1,5 @@ procedure Test.0 (): - let Test.9 : [, C List *self] = TagId(1) ; - let Test.10 : [C List [, C List *self], C U16, C ] = TagId(2) ; - let Test.12 : {[, C List *self], [C List [, C List *self], C U16, C ]} = Struct {Test.9, Test.10}; + let Test.4 : [, C List *self] = TagId(1) ; + let Test.5 : [C List [, C List *self], C U16, C ] = TagId(2) ; + let Test.12 : {[, C List *self], [C List [, C List *self], C U16, C ]} = Struct {Test.4, Test.5}; ret Test.12; diff --git a/crates/compiler/test_mono/generated/instantiate_annotated_as_recursive_alias_polymorphic_expr.txt b/crates/compiler/test_mono/generated/instantiate_annotated_as_recursive_alias_polymorphic_expr.txt index 236c504964..8c1945592c 100644 --- a/crates/compiler/test_mono/generated/instantiate_annotated_as_recursive_alias_polymorphic_expr.txt +++ b/crates/compiler/test_mono/generated/instantiate_annotated_as_recursive_alias_polymorphic_expr.txt @@ -1,3 +1,3 @@ procedure Test.0 (): - let Test.5 : [, C List *self] = TagId(1) ; - ret Test.5; + let Test.3 : [, C List *self] = TagId(1) ; + ret Test.3; diff --git a/crates/compiler/test_mono/generated/instantiate_annotated_as_recursive_alias_toplevel.txt b/crates/compiler/test_mono/generated/instantiate_annotated_as_recursive_alias_toplevel.txt index abad1c4dbb..31c1ff26ea 100644 --- a/crates/compiler/test_mono/generated/instantiate_annotated_as_recursive_alias_toplevel.txt +++ b/crates/compiler/test_mono/generated/instantiate_annotated_as_recursive_alias_toplevel.txt @@ -1,7 +1,7 @@ -procedure Test.4 (): +procedure Test.2 (): let Test.7 : [, C List *self] = TagId(1) ; ret Test.7; procedure Test.0 (): - let Test.6 : [, C List *self] = CallByName Test.4; + let Test.6 : [, C List *self] = CallByName Test.2; ret Test.6; diff --git a/crates/compiler/test_mono/generated/is_nil.txt b/crates/compiler/test_mono/generated/is_nil.txt index d12f69a017..ce1ba7a55a 100644 --- a/crates/compiler/test_mono/generated/is_nil.txt +++ b/crates/compiler/test_mono/generated/is_nil.txt @@ -1,4 +1,4 @@ -procedure Test.3 (Test.4): +procedure Test.2 (Test.4): let Test.13 : Int1 = 1i64; let Test.14 : Int1 = GetTagId Test.4; let Test.15 : Int1 = lowlevel Eq Test.13 Test.14; @@ -13,6 +13,6 @@ procedure Test.0 (): let Test.16 : I64 = 2i64; let Test.17 : [, C I64 *self] = TagId(1) ; let Test.10 : [, C I64 *self] = TagId(0) Test.16 Test.17; - let Test.9 : Int1 = CallByName Test.3 Test.10; + let Test.9 : Int1 = CallByName Test.2 Test.10; dec Test.10; ret Test.9; diff --git a/crates/compiler/test_mono/generated/issue_2583_specialize_errors_behind_unified_branches.txt b/crates/compiler/test_mono/generated/issue_2583_specialize_errors_behind_unified_branches.txt index 469ab72a85..3b709d5968 100644 --- a/crates/compiler/test_mono/generated/issue_2583_specialize_errors_behind_unified_branches.txt +++ b/crates/compiler/test_mono/generated/issue_2583_specialize_errors_behind_unified_branches.txt @@ -42,14 +42,14 @@ procedure Num.22 (#Attr.2, #Attr.3): ret Num.257; procedure Str.27 (Str.89): - let Str.195 : [C Int1, C I64] = CallByName Str.68 Str.89; + let Str.195 : [C Int1, C I64] = CallByName Str.62 Str.89; ret Str.195; procedure Str.47 (#Attr.2): let Str.203 : {I64, U8} = lowlevel StrToNum #Attr.2; ret Str.203; -procedure Str.68 (Str.190): +procedure Str.62 (Str.190): let Str.191 : {I64, U8} = CallByName Str.47 Str.190; let Str.201 : U8 = StructAtIndex 1 Str.191; let Str.202 : U8 = 0i64; diff --git a/crates/compiler/test_mono/generated/issue_2810.txt b/crates/compiler/test_mono/generated/issue_2810.txt index f898de15a3..b08d0ef95c 100644 --- a/crates/compiler/test_mono/generated/issue_2810.txt +++ b/crates/compiler/test_mono/generated/issue_2810.txt @@ -2,5 +2,5 @@ procedure Test.0 (): let Test.19 : [C [C [C *self, C ]], C ] = TagId(1) ; let Test.17 : [C [C *self, C ]] = TagId(0) Test.19; let Test.16 : [C [C [C *self, C ]], C ] = TagId(0) Test.17; - let Test.7 : [C [C *self, C ]] = TagId(0) Test.16; - ret Test.7; + let Test.4 : [C [C *self, C ]] = TagId(0) Test.16; + ret Test.4; diff --git a/crates/compiler/test_mono/generated/opaque_assign_to_symbol.txt b/crates/compiler/test_mono/generated/opaque_assign_to_symbol.txt index f2e8378359..d99acaaf80 100644 --- a/crates/compiler/test_mono/generated/opaque_assign_to_symbol.txt +++ b/crates/compiler/test_mono/generated/opaque_assign_to_symbol.txt @@ -1,8 +1,8 @@ -procedure Test.3 (Test.4): +procedure Test.2 (Test.4): let Test.8 : [C {}, C U8] = TagId(1) Test.4; ret Test.8; procedure Test.0 (): let Test.7 : U8 = 98i64; - let Test.6 : [C {}, C U8] = CallByName Test.3 Test.7; + let Test.6 : [C {}, C U8] = CallByName Test.2 Test.7; ret Test.6; diff --git a/crates/compiler/test_mono/generated/peano.txt b/crates/compiler/test_mono/generated/peano.txt index ee5393219a..b8610aadae 100644 --- a/crates/compiler/test_mono/generated/peano.txt +++ b/crates/compiler/test_mono/generated/peano.txt @@ -2,5 +2,5 @@ procedure Test.0 (): let Test.11 : [, C *self] = TagId(1) ; let Test.10 : [, C *self] = TagId(0) Test.11; let Test.9 : [, C *self] = TagId(0) Test.10; - let Test.3 : [, C *self] = TagId(0) Test.9; - ret Test.3; + let Test.2 : [, C *self] = TagId(0) Test.9; + ret Test.2; diff --git a/crates/compiler/test_mono/generated/peano1.txt b/crates/compiler/test_mono/generated/peano1.txt index 75c118328e..dc5104d009 100644 --- a/crates/compiler/test_mono/generated/peano1.txt +++ b/crates/compiler/test_mono/generated/peano1.txt @@ -2,10 +2,10 @@ procedure Test.0 (): let Test.15 : [, C *self] = TagId(1) ; let Test.14 : [, C *self] = TagId(0) Test.15; let Test.13 : [, C *self] = TagId(0) Test.14; - let Test.3 : [, C *self] = TagId(0) Test.13; + let Test.2 : [, C *self] = TagId(0) Test.13; let Test.10 : Int1 = 1i64; - let Test.11 : Int1 = GetTagId Test.3; - dec Test.3; + let Test.11 : Int1 = GetTagId Test.2; + dec Test.2; let Test.12 : Int1 = lowlevel Eq Test.10 Test.11; if Test.12 then let Test.8 : I64 = 0i64; diff --git a/crates/compiler/test_mono/generated/peano2.txt b/crates/compiler/test_mono/generated/peano2.txt index 36a67b1b66..2bddde8385 100644 --- a/crates/compiler/test_mono/generated/peano2.txt +++ b/crates/compiler/test_mono/generated/peano2.txt @@ -2,14 +2,14 @@ procedure Test.0 (): let Test.21 : [, C *self] = TagId(1) ; let Test.20 : [, C *self] = TagId(0) Test.21; let Test.19 : [, C *self] = TagId(0) Test.20; - let Test.3 : [, C *self] = TagId(0) Test.19; + let Test.2 : [, C *self] = TagId(0) Test.19; let Test.16 : Int1 = 0i64; - let Test.17 : Int1 = GetTagId Test.3; + let Test.17 : Int1 = GetTagId Test.2; let Test.18 : Int1 = lowlevel Eq Test.16 Test.17; if Test.18 then - let Test.12 : [, C *self] = UnionAtIndex (Id 0) (Index 0) Test.3; + let Test.12 : [, C *self] = UnionAtIndex (Id 0) (Index 0) Test.2; inc Test.12; - dec Test.3; + dec Test.2; let Test.13 : Int1 = 0i64; let Test.14 : Int1 = GetTagId Test.12; dec Test.12; @@ -21,6 +21,6 @@ procedure Test.0 (): let Test.9 : I64 = 0i64; ret Test.9; else - dec Test.3; + dec Test.2; let Test.10 : I64 = 0i64; ret Test.10; diff --git a/crates/compiler/test_mono/generated/specialize_ability_call.txt b/crates/compiler/test_mono/generated/specialize_ability_call.txt index ebc12cb8bf..4ca851d43e 100644 --- a/crates/compiler/test_mono/generated/specialize_ability_call.txt +++ b/crates/compiler/test_mono/generated/specialize_ability_call.txt @@ -1,7 +1,7 @@ -procedure Test.7 (Test.9): +procedure Test.4 (Test.9): ret Test.9; procedure Test.0 (): let Test.11 : U64 = 1234i64; - let Test.10 : U64 = CallByName Test.7 Test.11; + let Test.10 : U64 = CallByName Test.4 Test.11; ret Test.10; diff --git a/crates/reporting/tests/test_reporting.rs b/crates/reporting/tests/test_reporting.rs index cb111f9fe1..a8182c3894 100644 --- a/crates/reporting/tests/test_reporting.rs +++ b/crates/reporting/tests/test_reporting.rs @@ -8710,11 +8710,11 @@ All branches in an `if` must have the same type! mulHashes : Hash, Hash -> U64 mulHashes = \x, y -> hash x * hash y - Id := U64 - hash = \@Id n -> n + Id := U64 has [Hash {hash: hashId}] + hashId = \@Id n -> n - Three := {} - hash = \@Three _ -> 3 + Three := {} has [Hash {hash: hashThree}] + hashThree = \@Three _ -> 3 result = mulHashes (@Id 100) (@Three {}) "#