summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/wasm-interpreter.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/wasm-interpreter.h b/src/wasm-interpreter.h
index 42bcbaebc..008825632 100644
--- a/src/wasm-interpreter.h
+++ b/src/wasm-interpreter.h
@@ -1643,7 +1643,8 @@ public:
if (init.breaking()) {
return init;
}
- auto value = init.getSingleValue();
+ auto field = curr->type.getHeapType().getArray().element;
+ auto value = truncateForPacking(init.getSingleValue(), field);
for (Index i = 0; i < num; i++) {
data[i] = value;
}