forked from solstice/solstice
Fix function calling bug
This commit is contained in:
@@ -617,6 +617,7 @@ namespace Solstice {
|
||||
code.push_back(inputCodeBlock);
|
||||
break;
|
||||
}
|
||||
exists(children[0]);
|
||||
std::string fnToCall = children[0].outputId;
|
||||
|
||||
break;
|
||||
@@ -1179,6 +1180,7 @@ namespace Solstice {
|
||||
node.nodeType = SolNodeType::Expression;
|
||||
rootNode.addNode(node);
|
||||
}
|
||||
break;
|
||||
}
|
||||
case SolNodeType::FunctionDef: {
|
||||
SolFunction fn;
|
||||
|
||||
4
tests/function.sols
Normal file
4
tests/function.sols
Normal file
@@ -0,0 +1,4 @@
|
||||
def add(int a, int b) {
|
||||
return a + b
|
||||
}
|
||||
add(1, 2)
|
||||
Reference in New Issue
Block a user