Skip to content

Commit

Permalink
chore: Update snapshot tests and smallest program
Browse files Browse the repository at this point in the history
  • Loading branch information
spotandjake committed Oct 9, 2024
1 parent a3443c7 commit 9f8da61
Show file tree
Hide file tree
Showing 42 changed files with 194 additions and 314 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ basic functionality › pattern_match_unsafe_wasm
(i32.const 31)
)
(block $compile_block.7 (result i32)
(i32.const 11)
(i32.const 5)
)
(block $compile_block.28 (result i32)
(block $compile_store.9
Expand All @@ -161,7 +161,7 @@ basic functionality › pattern_match_unsafe_wasm
(i32.const 31)
)
(block $compile_block.10 (result i32)
(i32.const 9)
(i32.const 4)
)
(block $compile_block.27 (result i32)
(block $compile_store.12
Expand All @@ -184,7 +184,7 @@ basic functionality › pattern_match_unsafe_wasm
(i32.const 31)
)
(block $compile_block.13 (result i32)
(i32.const 7)
(i32.const 3)
)
(block $compile_block.26 (result i32)
(block $compile_store.15
Expand All @@ -207,7 +207,7 @@ basic functionality › pattern_match_unsafe_wasm
(i32.const 31)
)
(block $compile_block.16 (result i32)
(i32.const 5)
(i32.const 2)
)
(block $compile_block.25 (result i32)
(block $compile_store.18
Expand All @@ -230,7 +230,7 @@ basic functionality › pattern_match_unsafe_wasm
(i32.const 31)
)
(block $compile_block.19 (result i32)
(i32.const 3)
(i32.const 1)
)
(block $compile_block.24 (result i32)
(block $compile_store.21
Expand All @@ -253,10 +253,10 @@ basic functionality › pattern_match_unsafe_wasm
(i32.const 31)
)
(block $compile_block.22 (result i32)
(i32.const 1)
(i32.const 0)
)
(block $compile_block.23 (result i32)
(i32.const 13)
(i32.const 6)
)
)
)
Expand Down Expand Up @@ -295,10 +295,7 @@ basic functionality › pattern_match_unsafe_wasm
(block $switch.32_default (result i32)
(br_table $switch.32_branch_1 $switch.32_branch_2 $switch.32_branch_3 $switch.32_branch_4 $switch.32_branch_5 $switch.32_branch_6 $switch.32_branch_7 $switch.32_default $switch.32_default
(i32.const 0)
(i32.shr_s
(local.get $17)
(i32.const 1)
)
(local.get $17)
)
)
)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -174,10 +174,7 @@ pattern matching › record_match_3
(block $switch.16_default (result i32)
(br_table $switch.16_branch_1 $switch.16_default $switch.16_default
(i32.const 0)
(i32.shr_s
(i32.const 1)
(i32.const 1)
)
(i32.const 0)
)
)
)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -241,7 +241,7 @@ pattern matching › adt_match_deep
(i32.const 1879048190)
)
)
(i32.const 3)
(i32.const 1)
)
(block $compile_block.27 (result i32)
(block $compile_store.24
Expand All @@ -266,7 +266,7 @@ pattern matching › adt_match_deep
(i32.const 31)
)
(block $compile_block.25 (result i32)
(i32.const 1)
(i32.const 0)
)
(block $compile_block.26
(unreachable)
Expand Down Expand Up @@ -298,10 +298,7 @@ pattern matching › adt_match_deep
(block $switch.32_default (result i32)
(br_table $switch.32_branch_1 $switch.32_branch_2 $switch.32_default $switch.32_default
(i32.const 0)
(i32.shr_s
(local.get $14)
(i32.const 1)
)
(local.get $14)
)
)
)
Expand Down
19 changes: 8 additions & 11 deletions compiler/test/__snapshots__/pattern_matching.0ad4ac05.0.snapshot
Original file line number Diff line number Diff line change
Expand Up @@ -577,10 +577,10 @@ pattern matching › tuple_match_deep4
(i32.const 1879048190)
)
)
(i32.const 7)
(i32.const 3)
)
(block $compile_block.72 (result i32)
(i32.const 9)
(i32.const 4)
)
)
(block $cleanup.66 (result i32)
Expand Down Expand Up @@ -684,10 +684,10 @@ pattern matching › tuple_match_deep4
(i32.const 1879048190)
)
)
(i32.const 5)
(i32.const 2)
)
(block $compile_block.80 (result i32)
(i32.const 9)
(i32.const 4)
)
)
)
Expand Down Expand Up @@ -777,10 +777,10 @@ pattern matching › tuple_match_deep4
(i32.const 1879048190)
)
)
(i32.const 3)
(i32.const 1)
)
(block $compile_block.88 (result i32)
(i32.const 9)
(i32.const 4)
)
)
)
Expand Down Expand Up @@ -848,7 +848,7 @@ pattern matching › tuple_match_deep4
(i32.const 1879048190)
)
)
(i32.const 1)
(i32.const 0)
)
(block $compile_block.95
(unreachable)
Expand Down Expand Up @@ -892,10 +892,7 @@ pattern matching › tuple_match_deep4
(block $switch.101_default (result i32)
(br_table $switch.101_branch_1 $switch.101_branch_2 $switch.101_branch_3 $switch.101_branch_4 $switch.101_branch_5 $switch.101_default $switch.101_default
(i32.const 0)
(i32.shr_s
(local.get $32)
(i32.const 1)
)
(local.get $32)
)
)
)
Expand Down
19 changes: 8 additions & 11 deletions compiler/test/__snapshots__/pattern_matching.0bb6923e.0.snapshot
Original file line number Diff line number Diff line change
Expand Up @@ -542,10 +542,10 @@ pattern matching › adt_match_4
(i32.const 1879048190)
)
)
(i32.const 7)
(i32.const 3)
)
(block $compile_block.61 (result i32)
(i32.const 9)
(i32.const 4)
)
)
(block $cleanup.56 (result i32)
Expand Down Expand Up @@ -627,10 +627,10 @@ pattern matching › adt_match_4
(i32.const 1879048190)
)
)
(i32.const 5)
(i32.const 2)
)
(block $compile_block.68 (result i32)
(i32.const 9)
(i32.const 4)
)
)
)
Expand Down Expand Up @@ -698,10 +698,10 @@ pattern matching › adt_match_4
(i32.const 1879048190)
)
)
(i32.const 3)
(i32.const 1)
)
(block $compile_block.75 (result i32)
(i32.const 9)
(i32.const 4)
)
)
)
Expand Down Expand Up @@ -747,7 +747,7 @@ pattern matching › adt_match_4
(i32.const 31)
)
(block $compile_block.80 (result i32)
(i32.const 1)
(i32.const 0)
)
(block $compile_block.81
(unreachable)
Expand Down Expand Up @@ -785,10 +785,7 @@ pattern matching › adt_match_4
(block $switch.87_default (result i32)
(br_table $switch.87_branch_1 $switch.87_branch_2 $switch.87_branch_3 $switch.87_branch_4 $switch.87_branch_5 $switch.87_default $switch.87_default
(i32.const 0)
(i32.shr_s
(local.get $25)
(i32.const 1)
)
(local.get $25)
)
)
)
Expand Down
15 changes: 6 additions & 9 deletions compiler/test/__snapshots__/pattern_matching.0fa61137.0.snapshot
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ pattern matching › low_level_constant_match_2
(i32.const 31)
)
(block $compile_block.6 (result i32)
(i32.const 1)
(i32.const 0)
)
(block $compile_block.15 (result i32)
(block $compile_store.8
Expand All @@ -117,7 +117,7 @@ pattern matching › low_level_constant_match_2
(i32.const 31)
)
(block $compile_block.9 (result i32)
(i32.const 3)
(i32.const 1)
)
(block $compile_block.14 (result i32)
(block $compile_store.11
Expand All @@ -140,10 +140,10 @@ pattern matching › low_level_constant_match_2
(i32.const 31)
)
(block $compile_block.12 (result i32)
(i32.const 5)
(i32.const 2)
)
(block $compile_block.13 (result i32)
(i32.const 7)
(i32.const 3)
)
)
)
Expand All @@ -170,10 +170,7 @@ pattern matching › low_level_constant_match_2
(block $switch.18_default (result i32)
(br_table $switch.18_branch_1 $switch.18_branch_2 $switch.18_branch_3 $switch.18_branch_4 $switch.18_default $switch.18_default
(i32.const 0)
(i32.shr_s
(local.get $8)
(i32.const 1)
)
(local.get $8)
)
)
)
Expand Down Expand Up @@ -230,7 +227,7 @@ pattern matching › low_level_constant_match_2
(block $do_backpatches.26
)
)
(i32.const 1)
(i32.const 0)
)
)
(func $_start
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -158,10 +158,7 @@ pattern matching › record_match_2
(block $switch.14_default (result i32)
(br_table $switch.14_branch_1 $switch.14_default $switch.14_default
(i32.const 0)
(i32.shr_s
(i32.const 1)
(i32.const 1)
)
(i32.const 0)
)
)
)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -109,10 +109,10 @@ pattern matching › constant_match_3
(i32.const 31)
)
(block $compile_block.9 (result i32)
(i32.const 3)
(i32.const 1)
)
(block $compile_block.10 (result i32)
(i32.const 5)
(i32.const 2)
)
)
)
Expand All @@ -131,10 +131,7 @@ pattern matching › constant_match_3
(block $switch.13_default (result i32)
(br_table $switch.13_branch_1 $switch.13_branch_2 $switch.13_branch_3 $switch.13_default $switch.13_default
(i32.const 0)
(i32.shr_s
(local.get $9)
(i32.const 1)
)
(local.get $9)
)
)
)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -298,10 +298,10 @@ pattern matching › guarded_match_2
(i32.const 1879048190)
)
)
(i32.const 1)
(i32.const 0)
)
(block $compile_block.26 (result i32)
(i32.const 3)
(i32.const 1)
)
)
)
Expand Down Expand Up @@ -340,10 +340,7 @@ pattern matching › guarded_match_2
(block $switch.31_default (result i32)
(br_table $switch.31_branch_1 $switch.31_branch_2 $switch.31_default $switch.31_default
(i32.const 0)
(i32.shr_s
(local.get $14)
(i32.const 1)
)
(local.get $14)
)
)
)
Expand Down
15 changes: 6 additions & 9 deletions compiler/test/__snapshots__/pattern_matching.25930935.0.snapshot
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ pattern matching › low_level_constant_match_3
(i32.const 31)
)
(block $compile_block.6 (result i32)
(i32.const 1)
(i32.const 0)
)
(block $compile_block.15 (result i32)
(block $compile_store.8
Expand All @@ -117,7 +117,7 @@ pattern matching › low_level_constant_match_3
(i32.const 31)
)
(block $compile_block.9 (result i32)
(i32.const 3)
(i32.const 1)
)
(block $compile_block.14 (result i32)
(block $compile_store.11
Expand All @@ -140,10 +140,10 @@ pattern matching › low_level_constant_match_3
(i32.const 31)
)
(block $compile_block.12 (result i32)
(i32.const 5)
(i32.const 2)
)
(block $compile_block.13 (result i32)
(i32.const 7)
(i32.const 3)
)
)
)
Expand All @@ -170,10 +170,7 @@ pattern matching › low_level_constant_match_3
(block $switch.18_default (result i32)
(br_table $switch.18_branch_1 $switch.18_branch_2 $switch.18_branch_3 $switch.18_branch_4 $switch.18_default $switch.18_default
(i32.const 0)
(i32.shr_s
(local.get $8)
(i32.const 1)
)
(local.get $8)
)
)
)
Expand Down Expand Up @@ -230,7 +227,7 @@ pattern matching › low_level_constant_match_3
(block $do_backpatches.26
)
)
(i32.const 1)
(i32.const 0)
)
)
(func $_start
Expand Down
Loading

0 comments on commit 9f8da61

Please sign in to comment.