summaryrefslogtreecommitdiff
path: root/test/lit/passes/precompute-strings.wast
diff options
context:
space:
mode:
Diffstat (limited to 'test/lit/passes/precompute-strings.wast')
-rw-r--r--test/lit/passes/precompute-strings.wast28
1 files changed, 27 insertions, 1 deletions
diff --git a/test/lit/passes/precompute-strings.wast b/test/lit/passes/precompute-strings.wast
index f70430648..c9facfe36 100644
--- a/test/lit/passes/precompute-strings.wast
+++ b/test/lit/passes/precompute-strings.wast
@@ -1,11 +1,21 @@
-;; NOTE: Assertions have been generated by update_lit_checks.py and should not be edited.
+;; NOTE: Assertions have been generated by update_lit_checks.py --all-items and should not be edited.
;; RUN: wasm-opt %s --precompute -all -S -o - | filecheck %s
(module
+ ;; CHECK: (type $0 (func (result i32)))
+
+ ;; CHECK: (type $1 (func (result (ref string))))
+
;; CHECK: (type $array16 (array (mut i16)))
(type $array16 (array (mut i16)))
+ ;; CHECK: (export "get_codepoint-bad" (func $get_codepoint-bad))
+
+ ;; CHECK: (export "slice" (func $slice))
+
+ ;; CHECK: (export "slice-bad" (func $slice-bad))
+
;; CHECK: (func $eq-no (type $0) (result i32)
;; CHECK-NEXT: (i32.const 0)
;; CHECK-NEXT: )
@@ -36,6 +46,22 @@
)
)
+ ;; CHECK: (func $concat-bad (type $0) (result i32)
+ ;; CHECK-NEXT: (string.eq
+ ;; CHECK-NEXT: (string.concat
+ ;; CHECK-NEXT: (string.const "a\f0")
+ ;; CHECK-NEXT: (string.const "b")
+ ;; CHECK-NEXT: )
+ ;; CHECK-NEXT: (string.const "a\f0b")
+ ;; CHECK-NEXT: )
+ ;; CHECK-NEXT: )
+ (func $concat-bad (result i32)
+ (string.eq
+ (string.concat (string.const "a\F0") (string.const "b"))
+ (string.const "a\F0b")
+ )
+ )
+
;; CHECK: (func $length (type $0) (result i32)
;; CHECK-NEXT: (i32.const 7)
;; CHECK-NEXT: )