Hi. Great post!
Zig newbie question.
When I try to build the bechmark (blog branch) with Zig 0.9.0 using -Dc (Linux) the compiler throws an error:
-Dc
/tmp/zap/benchmarks/zig (blog)$ zig build -Dc ./async.zig:64:29: error: expected type '*std.mem.Allocator', found 'std.mem.Allocator' allocator = std.heap.c_allocator; ^ ./qsort.zig:7:21: note: called from here return Async.run(asyncMain, .{}); ^ ./qsort.zig:6:20: note: called from here pub fn main() void { ^ /snap/zig/4409/lib/std/mem/Allocator.zig:1:1: note: std.mem.Allocator declared here //! The standard memory allocation interface. ^ qsort...The following command exited with error code 1: /snap/zig/4409/zig build-exe /tmp/zap/benchmarks/zig/qsort.zig -lc --cache-dir /tmp/zap/benchmarks/zig/zig-cache --global-cache-dir /home/daniel/.cache/zig --name qsort --pkg-begin thread_pool /tmp/zap/src/thread_pool.zig --pkg-end --enable-cache error: the following build command failed with exit code 1:
What is happening?
The code in the example is out of date with the current master branch and needs to be updated. This particular error was because allocator interfaces changed
Oh I see. Thank you!
Are you sure you want to hide this comment? It will become hidden in your post, but will still be visible via the comment's permalink.
Hide child comments as well
Confirm
For further actions, you may consider blocking this person and/or reporting abuse
Take off every Zig!
Hi. Great post!
Zig newbie question.
When I try to build the bechmark (blog branch) with Zig 0.9.0 using
-Dc
(Linux) the compiler throws an error:What is happening?
The code in the example is out of date with the current master branch and needs to be updated. This particular error was because allocator interfaces changed
Oh I see.
Thank you!