aboutsummaryrefslogtreecommitdiff
path: root/boot/ast.cc
diff options
context:
space:
mode:
Diffstat (limited to 'boot/ast.cc')
-rw-r--r--boot/ast.cc12
1 files changed, 10 insertions, 2 deletions
diff --git a/boot/ast.cc b/boot/ast.cc
index b8647f4..edf1237 100644
--- a/boot/ast.cc
+++ b/boot/ast.cc
@@ -367,10 +367,15 @@ namespace elna::boot
}
if (unit->entry_point.has_value())
{
- traverse_body(this, unit->entry_point.value());
+ visit_entry_point(unit);
}
}
+ void walking_visitor::visit_entry_point(unit *unit)
+ {
+ traverse_body(this, unit->entry_point.value());
+ }
+
void walking_visitor::visit(type_declaration *declaration)
{
declaration->underlying_type().accept(this);
@@ -1033,10 +1038,13 @@ namespace elna::boot
std::vector<type_declaration *>&& types,
std::vector<variable_declaration *>&& variables,
std::vector<procedure_declaration *>&& procedures,
+ std::vector<identifier>&& parameters,
+ const source_position entry_position,
std::optional<procedure_body>&& body)
: node(position),
imports(std::move(imports)), types(std::move(types)), procedures(std::move(procedures)),
- variables(std::move(variables)), entry_point(std::move(body))
+ variables(std::move(variables)), entry_point(std::move(body)),
+ parameters(std::move(parameters)), entry_position(entry_position)
{
}