summary refs log tree commit diff
path: root/src/main.zig
diff options
context:
space:
mode:
Diffstat (limited to 'src/main.zig')
-rw-r--r--src/main.zig1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/main.zig b/src/main.zig
index c65ef4b..86ba202 100644
--- a/src/main.zig
+++ b/src/main.zig
@@ -50,6 +50,7 @@ fn process_buf(buf: []u8, allocator: std.mem.Allocator) !void {
     }
 
     const source_parser = try parser.Parser.init(token_list.items, allocator);
+    errdefer source_parser.deinit(null);
     const ast = try source_parser.parse();
     defer source_parser.deinit(@constCast(ast));
     std.debug.print("AST: {any}\n", .{ast});