summaryrefslogtreecommitdiff
path: root/test/lit/passes/string-gathering.wast
diff options
context:
space:
mode:
Diffstat (limited to 'test/lit/passes/string-gathering.wast')
-rw-r--r--test/lit/passes/string-gathering.wast20
1 files changed, 20 insertions, 0 deletions
diff --git a/test/lit/passes/string-gathering.wast b/test/lit/passes/string-gathering.wast
index 657858fc0..8c315ddc1 100644
--- a/test/lit/passes/string-gathering.wast
+++ b/test/lit/passes/string-gathering.wast
@@ -27,12 +27,22 @@
;; CHECK: (global $global2 stringref (global.get $string.const_bar))
;; LOWER: (type $0 (func))
+ ;; LOWER: (type $1 (array (mut i16)))
+
+ ;; LOWER: (type $2 (func (param (ref null $1) i32 i32) (result (ref extern))))
+
+ ;; LOWER: (type $3 (func (param i32) (result (ref extern))))
+
;; LOWER: (import "string.const" "0" (global $string.const_bar (ref extern)))
;; LOWER: (import "string.const" "1" (global $string.const_other (ref extern)))
;; LOWER: (import "string.const" "2" (global $global (ref extern)))
+ ;; LOWER: (import "wasm:js-string" "fromCharCodeArray" (func $fromCharCodeArray (type $2) (param (ref null $1) i32 i32) (result (ref extern))))
+
+ ;; LOWER: (import "wasm:js-string" "fromCodePoint" (func $fromCodePoint (type $3) (param i32) (result (ref extern))))
+
;; LOWER: (global $global2 externref (global.get $string.const_bar))
(global $global2 (ref null string) (string.const "bar"))
@@ -111,6 +121,12 @@
;; Multiple possible reusable globals. Also test ignoring of imports.
(module
;; CHECK: (import "a" "b" (global $import (ref string)))
+ ;; LOWER: (type $0 (array (mut i16)))
+
+ ;; LOWER: (type $1 (func (param (ref null $0) i32 i32) (result (ref extern))))
+
+ ;; LOWER: (type $2 (func (param i32) (result (ref extern))))
+
;; LOWER: (import "a" "b" (global $import (ref extern)))
(import "a" "b" (global $import (ref string)))
@@ -122,6 +138,10 @@
;; LOWER: (import "string.const" "1" (global $global4 (ref extern)))
+ ;; LOWER: (import "wasm:js-string" "fromCharCodeArray" (func $fromCharCodeArray (type $1) (param (ref null $0) i32 i32) (result (ref extern))))
+
+ ;; LOWER: (import "wasm:js-string" "fromCodePoint" (func $fromCodePoint (type $2) (param i32) (result (ref extern))))
+
;; LOWER: (global $global2 (ref extern) (global.get $global1))
(global $global2 (ref string) (string.const "foo"))