summaryrefslogtreecommitdiff
path: root/test/mutable-global.wasm.fromBinary
diff options
context:
space:
mode:
authorSam Clegg <sbc@chromium.org>2018-11-30 08:45:29 -0800
committerGitHub <noreply@github.com>2018-11-30 08:45:29 -0800
commitf16a7605b8226502062c6ca24323d431669c90ec (patch)
tree325a9184c5b1c562fd27bc89ad1a35b951cd34f9 /test/mutable-global.wasm.fromBinary
parent955a9a9440f26438ba50e35ebe57a86a5111d4a1 (diff)
downloadbinaryen-f16a7605b8226502062c6ca24323d431669c90ec.tar.gz
binaryen-f16a7605b8226502062c6ca24323d431669c90ec.tar.bz2
binaryen-f16a7605b8226502062c6ca24323d431669c90ec.zip
Add support for a mutable globals as a Feature (#1785)
This picks up from #1644 and indeed borrows the test case from there.
Diffstat (limited to 'test/mutable-global.wasm.fromBinary')
-rw-r--r--test/mutable-global.wasm.fromBinary13
1 files changed, 13 insertions, 0 deletions
diff --git a/test/mutable-global.wasm.fromBinary b/test/mutable-global.wasm.fromBinary
new file mode 100644
index 000000000..aba18cdc4
--- /dev/null
+++ b/test/mutable-global.wasm.fromBinary
@@ -0,0 +1,13 @@
+(module
+ (type $0 (func))
+ (import "env" "global-mut" (global $gimport$0 (mut i32)))
+ (func $0 (; 0 ;) (type $0)
+ (set_global $gimport$0
+ (i32.add
+ (get_global $gimport$0)
+ (i32.const 1)
+ )
+ )
+ )
+)
+