We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
The following code:
var gpa = std.heap.GeneralPurposeAllocator(.{}){}; defer std.debug.assert(gpa.deinit() == .ok); var alloc = gpa.allocator(); const params = comptime clap.parseParamsComptime( \\-h Display this help. \\<str> The host to connect to. \\ ); var diag = clap.Diagnostic{}; var res = clap.parse(clap.Help, ¶ms, clap.parsers.default, .{ .diagnostic = &diag, .allocator = alloc, }) catch |err| { diag.report(io.getStdErr().writer(), err) catch {}; return err; }; defer res.deinit();
Errors out while building:
vscode ➜ /workspaces/my-project (main) $ zig build run -- -h zig build-exe my-project Debug native: error: the following command terminated unexpectedly: /usr/local/lib/zig/zig build-exe /workspaces/my-project/src/main.zig --cache-dir /workspaces/my-project/zig-cache --global-cache-dir /home/vscode/.cache/zig --name my-project --mod clap::/home/vscode/.cache/zig/p/1220f48518ce22882e102255ed3bcdb7aeeb4891f50b2cdd3bd74b5b2e24d3149ba2/clap.zig --deps clap --listen=- Build Summary: 0/5 steps succeeded; 1 failed (disable with --summary none) run transitive failure └─ run my-project transitive failure ├─ zig build-exe my-project Debug native failure └─ install transitive failure └─ install my-project transitive failure └─ zig build-exe my-project Debug native (reused) error: the following build command failed with exit code 1: /workspaces/my-project/zig-cache/o/0eb5808b79de382229c649195106f6bc/build /usr/local/lib/zig/zig /workspaces/my-project /workspaces/my-project/zig-cache /home/vscode/.cache/zig run -- -h
It works fine once I change the params to:
const params = comptime clap.parseParamsComptime( \\-h,--help Display this help. \\<str> The host to connect to. \\ );
The text was updated successfully, but these errors were encountered:
Hmm. I don't see a compiler error. I suspect a compiler crash. Is this the same as #84 ?
Sorry, something went wrong.
No branches or pull requests
The following code:
Errors out while building:
It works fine once I change the params to:
The text was updated successfully, but these errors were encountered: