summaryrefslogtreecommitdiff
path: root/src/s2wasm.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/s2wasm.h')
-rw-r--r--src/s2wasm.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/s2wasm.h b/src/s2wasm.h
index 7c42a81b0..b3c22d83d 100644
--- a/src/s2wasm.h
+++ b/src/s2wasm.h
@@ -895,6 +895,16 @@ private:
for (size_t i = 0, e = size; i < e; i++) {
raw->push_back(0);
}
+ } else if (match(".int8")) {
+ size_t size = raw->size();
+ raw->resize(size + 1);
+ (*(int8_t*)(&(*raw)[size])) = getInt();
+ zero = false;
+ } else if (match(".int16")) {
+ size_t size = raw->size();
+ raw->resize(size + 2);
+ (*(int16_t*)(&(*raw)[size])) = getInt();
+ zero = false;
} else if (match(".int32")) {
size_t size = raw->size();
raw->resize(size + 4);