diff options
Diffstat (limited to 'src/wasm-builder.h')
-rw-r--r-- | src/wasm-builder.h | 24 |
1 files changed, 21 insertions, 3 deletions
diff --git a/src/wasm-builder.h b/src/wasm-builder.h index f636ea799..eec86bc50 100644 --- a/src/wasm-builder.h +++ b/src/wasm-builder.h @@ -1063,9 +1063,8 @@ public: ret->finalize(); return ret; } - StringIterMove* makeStringIterMove(StringIterMoveOp op, - Expression* ref, - Expression* num = nullptr) { + StringIterMove* + makeStringIterMove(StringIterMoveOp op, Expression* ref, Expression* num) { auto* ret = wasm.allocator.alloc<StringIterMove>(); ret->op = op; ret->ref = ref; @@ -1073,6 +1072,25 @@ public: ret->finalize(); return ret; } + StringSliceWTF* makeStringSliceWTF(StringSliceWTFOp op, + Expression* ref, + Expression* start, + Expression* end) { + auto* ret = wasm.allocator.alloc<StringSliceWTF>(); + ret->op = op; + ret->ref = ref; + ret->start = start; + ret->end = end; + ret->finalize(); + return ret; + } + StringSliceIter* makeStringSliceIter(Expression* ref, Expression* num) { + auto* ret = wasm.allocator.alloc<StringSliceIter>(); + ret->ref = ref; + ret->num = num; + ret->finalize(); + return ret; + } // Additional helpers |