aboutsummaryrefslogtreecommitdiff
path: root/src/interpreter.zig
diff options
context:
space:
mode:
authorJulien Dessaux2022-12-01 22:46:01 +0100
committerJulien Dessaux2022-12-01 23:00:42 +0100
commit860ebc4fd45e3d9865d95e80d3d80d5dd10c12bf (patch)
tree9a9f9f39ecc0abd9aa5ac801c5bb1ebdcc7c0b7d /src/interpreter.zig
parentUpdate compiler flags (diff)
downloadzigfunge98-860ebc4fd45e3d9865d95e80d3d80d5dd10c12bf.tar.gz
zigfunge98-860ebc4fd45e3d9865d95e80d3d80d5dd10c12bf.tar.bz2
zigfunge98-860ebc4fd45e3d9865d95e80d3d80d5dd10c12bf.zip
Fixed bugs from zig 0.10 upgrade (some real!)
Diffstat (limited to '')
-rw-r--r--src/interpreter.zig4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/interpreter.zig b/src/interpreter.zig
index 9fb98a1..760e008 100644
--- a/src/interpreter.zig
+++ b/src/interpreter.zig
@@ -13,13 +13,13 @@ pub const Interpreter = struct {
self.field.deinit();
self.allocator.destroy(self);
}
- pub fn init(allocator: std.mem.Allocator, fileReader: anytype, timestamp: fn () i64, args: []const []const u8, env: []const [*:0]const u8) !*Interpreter {
+ pub fn init(allocator: std.mem.Allocator, fileReader: anytype, timestamp: ?i64, args: []const []const u8, env: []const [*:0]const u8) !*Interpreter {
var i = try allocator.create(Interpreter);
errdefer allocator.destroy(i);
i.allocator = allocator;
i.field = try field.Field.init_from_reader(allocator, fileReader);
errdefer i.field.deinit();
- i.pointer = try pointer.Pointer.init(std.testing.allocator, i.field, timestamp, args, env);
+ i.pointer = try pointer.Pointer.init(allocator, i.field, timestamp, args, env);
errdefer i.pointer.deinit();
return i;
}