mbrock / wisp

Lisp in WebAssembly
https://wisp.town
GNU Affero General Public License v3.0
238 stars 6 forks source link

args.next expect 2 arguments, found 1 #1

Open glyh opened 2 years ago

glyh commented 2 years ago

I tried to compile this via make. Here's what I got:

cd core && zig build -Drelease-fast=true
./main.zig:60:26: error: expected 2 argument(s), found 1
    const cmd = args.next() orelse return help(stderr);
                         ^
/usr/lib/zig/std/process.zig:477:9: note: declared here
    pub fn next(self: *ArgIterator, allocator: Allocator) ?(NextError![:0]u8) {
        ^
wisp...The following command exited with error code 1:
/usr/bin/zig build-exe /tmp/wisp/core/main.zig -OReleaseFast --cache-dir /tmp/wisp/core/zig-cache --global-cache-dir /home/lyh/.cache/zig --name wisp --pkg-begin ziglyph /tmp/wisp/core/lib/ziglyph/src/ziglyph.zig --pkg-end --enable-cache 
error: the following build command failed with exit code 1:
/tmp/wisp/core/zig-cache/o/ec88ea5a2a45490eb5c7cb162ca3b9ab/build /usr/bin/zig /tmp/wisp/core /tmp/wisp/core/zig-cache /home/lyh/.cache/zig -Drelease-fast=true
make: *** [Makefile:3: core-fast] Error 1

Linux version: Linux arch 5.17.1-arch1-1 #1 SMP PREEMPT Mon, 28 Mar 2022 20:55:33 +0000 x86_64 GNU/Linux Zig version: 0.9.1

mbrock commented 2 years ago

Oh, I’m using a newer nightly version of Zig, I’m don’t remember why exactly… A lot of interesting work happening on Zig these days, the big compiler rewrite is approaching completion, so I hope to switch to that soon…

SuperSonicHub1 commented 2 years ago

Had the same issue, was able to get it working by installing version 0.10.0-dev.2058+a839ccc15.