File tree Expand file tree Collapse file tree 1 file changed +9
-3
lines changed Expand file tree Collapse file tree 1 file changed +9
-3
lines changed Original file line number Diff line number Diff line change 216216 (func $slice (export " slice" ) (result (ref string))
217217 ;; Slicing [3:6] here should definitely output "def".
218218 (stringview_wtf16.slice
219- (string.const " abcdefgh" )
219+ (string.as_wtf16
220+ (string.const " abcdefgh" )
221+ )
220222 (i32.const 3 )
221223 (i32.const 6 )
222224 )
223225 )
224226
225227 ;; CHECK: (func $slice-bad (type $2) (result (ref string))
226228 ;; CHECK-NEXT: (stringview_wtf16.slice
227- ;; CHECK-NEXT: (string.const "abcd\c2\a3fgh")
229+ ;; CHECK-NEXT: (string.as_wtf16
230+ ;; CHECK-NEXT: (string.const "abcd\c2\a3fgh")
231+ ;; CHECK-NEXT: )
228232 ;; CHECK-NEXT: (i32.const 3)
229233 ;; CHECK-NEXT: (i32.const 6)
230234 ;; CHECK-NEXT: )
233237 ;; This slice contains non-ascii, so we do not optimize.
234238 (stringview_wtf16.slice
235239 ;; abcd£fgh
236- (string.const " abcd\C2\A3 fgh" )
240+ (string.as_wtf16
241+ (string.const " abcd\C2\A3 fgh" )
242+ )
237243 (i32.const 3 )
238244 (i32.const 6 )
239245 )
You can’t perform that action at this time.
0 commit comments