summaryrefslogtreecommitdiff
path: root/test/roundtrip/fold-try.txt
blob: 412e34ca42a98bb6d0ec4fc9dd2c2e803ad7fbef (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
;;; TOOL: run-roundtrip
;;; ARGS: --stdout --fold-exprs --enable-exceptions --debug-names
(module
  (func (result i32)
    try (result i32)
      i32.const 6
    end
    drop
    try (result i32)
      nop
      i32.const 7
    catch_all
      i32.const 8
    end
  )
)
(;; STDOUT ;;;
(module
  (type (;0;) (func (result i32)))
  (func (;0;) (type 0) (result i32)
    (drop
      (try (result i32)  ;; label = @1
        (do
          (i32.const 6))))
    (try (result i32)  ;; label = @1
      (do
        (nop)
        (i32.const 7))
      (catch_all
        (i32.const 8)))))
;;; STDOUT ;;)