Fix bug in codegen for functions with multiple parameters.
Prior to this, all mutable param variables would be bound to the same parameter.
This commit is contained in:
parent
3ffdcf4b88
commit
be503447b3
|
@ -564,6 +564,7 @@ bool BitcodeEmitter::emit(Function const& node) {
|
||||||
);
|
);
|
||||||
d->builder.CreateStore(argToAlloc, alloc);
|
d->builder.CreateStore(argToAlloc, alloc);
|
||||||
d->scope.push(arg.getName().getValue(), alloc);
|
d->scope.push(arg.getName().getValue(), alloc);
|
||||||
|
++argToAlloc;
|
||||||
}
|
}
|
||||||
|
|
||||||
for (Statement const& stat: node.getBody()) {
|
for (Statement const& stat: node.getBody()) {
|
||||||
|
|
Reference in New Issue
Block a user