aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAlon Zakai <alonzakai@gmail.com>2012-12-14 17:47:55 -0800
committerAlon Zakai <alonzakai@gmail.com>2012-12-14 17:47:55 -0800
commit287b34565b9313b4a70378618e0fa99bd5eed775 (patch)
tree479a22f5cb56f2dd5f26e5087be749bc07dce0fe /src
parentce587f9df8e6a7126b206cba7bd4e3256cc71abd (diff)
asm coerce alloca computations
Diffstat (limited to 'src')
-rw-r--r--src/jsifier.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/jsifier.js b/src/jsifier.js
index 9c3109ad..95c3536d 100644
--- a/src/jsifier.js
+++ b/src/jsifier.js
@@ -1189,7 +1189,7 @@ function JSify(data, functionsOnly, givenFunctions) {
makeFuncLineActor('alloca', function(item) {
if (typeof item.allocatedIndex === 'number') {
if (item.allocatedSize === 0) return ''; // This will not actually be shown - it's nativized
- return getFastValue('__stackBase__', '+', item.allocatedIndex.toString());
+ return asmCoercion(getFastValue('__stackBase__', '+', item.allocatedIndex.toString()), 'i32');
} else {
return RuntimeGenerator.stackAlloc(getFastValue(calcAllocatedSize(item.allocatedType), '*', item.allocatedNum));
}