[AST] Add CallExpr::createImplicitEmpty

Add a convenience constructor for an implicit
nullary call. This will become more useful when
the argument parameter starts taking an
ArgumentList.
This commit is contained in:
Hamish Knight
2021-07-28 23:14:43 +01:00
parent 1286bbedf1
commit c70f280e4a
9 changed files with 19 additions and 15 deletions

View File

@@ -239,7 +239,7 @@ private:
Closure->setBody(ClosureBody, /*isSingleExpression=*/false);
// Call the closure.
auto *ClosureCall = CallExpr::createImplicit(Ctx, Closure, {}, {});
auto *ClosureCall = CallExpr::createImplicitEmpty(Ctx, Closure);
ClosureCall->setThrows(false);
// TODO: typeCheckExpression() seems to assign types to everything here,