zig icon indicating copy to clipboard operation
zig copied to clipboard

Build system crashes when invalid name is passed as name positional argument

Open adamjedrzejewski opened this issue 4 years ago • 0 comments

Zig Version

0.10.0-dev.84+4f4f0bc6f

Steps to Reproduce

$ echo "pub fn main() void { }" > test.zig
$ zig build-exe --name "hello/world" test.zig

Expected Behavior

Exits with sensible error message. Alternatively if [name] is a valid path, writes the file at this path.

Actual Behavior

Exits with confusing error message.

LLVM failed to emit asm=(null), bin=zig-cache/o/4a02e1df819533dd3f86e6fc50688742/hello/world.o, ir=(null), bc=(null): No such file or directory

adamjedrzejewski avatar Jan 03 '22 22:01 adamjedrzejewski