File: unsafe_call.wast

package info (click to toggle)
binaryen 108-1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 35,424 kB
  • sloc: cpp: 151,487; javascript: 62,522; ansic: 13,124; python: 5,260; pascal: 441; sh: 75; asm: 27; makefile: 8
file content (14 lines) | stat: -rw-r--r-- 399 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
(module
  (memory 256 256)
  (data (i32.const 10) "waka waka waka waka waka")
  (export "test1" $test1)
  (func $test1
    (call $unsafe-to-call) ;; unsafe to call
    (i32.store (i32.const 12) (i32.const 115)) ;; a safe store, should alter memory
    (i32.store16 (i32.const 20) (i32.const 31353))
    (i32.store8 (i32.const 23) (i32.const 120))
  )
  (func $unsafe-to-call
    (unreachable)
  )
)