summaryrefslogtreecommitdiff
path: root/src/s2wasm.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/s2wasm.h')
-rw-r--r--src/s2wasm.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/s2wasm.h b/src/s2wasm.h
index dd507143b..634aa43e5 100644
--- a/src/s2wasm.h
+++ b/src/s2wasm.h
@@ -915,7 +915,7 @@ class S2WasmBuilder {
curr->align = curr->bytes;
if (attributes[0]) {
assert(strncmp(attributes[0], "p2align=", 8) == 0);
- curr->align = 1U << getInt(attributes[0] + 8);
+ curr->align = Address(1) << getInt(attributes[0] + 8);
}
setOutput(curr, assign);
};
@@ -938,7 +938,7 @@ class S2WasmBuilder {
curr->align = curr->bytes;
if (attributes[0]) {
assert(strncmp(attributes[0], "p2align=", 8) == 0);
- curr->align = 1U << getInt(attributes[0] + 8);
+ curr->align = Address(1) << getInt(attributes[0] + 8);
}
curr->value = inputs[1];
curr->finalize();
@@ -1430,7 +1430,7 @@ class S2WasmBuilder {
Address localAlign = 1;
if (*s == ',') {
skipComma();
- localAlign = 1 << getInt();
+ localAlign = Address(1) << getInt();
}
linkerObj->addStatic(size, std::max(align, localAlign), name);
}