commit dc68c210d82625aa5578912965e3be231accecc1
parent 7aea4128ab6216e5220429e316c8c9e6763656c0
Author: Sebastian <sebastian@sebsite.pw>
Date: Sun, 1 May 2022 23:22:23 -0400
haredoc: free imports after parsing
Signed-off-by: Sebastian <sebastian@sebsite.pw>
Diffstat:
1 file changed, 3 insertions(+), 0 deletions(-)
diff --git a/cmd/haredoc/main.ha b/cmd/haredoc/main.ha
@@ -131,6 +131,9 @@ export fn main() void = {
};
match (scan(in.path)) {
case let u: ast::subunit =>
+ for (let i = 0z; i < len(u.imports); i += 1) {
+ ast::import_finish(u.imports[i]);
+ };
append(decls, u.decls...);
case let err: error =>
fmt::fatal("Error:", strerror(err));