You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Expected the compiler to give any output and exit gracefully.
I looked a bit around and 18518 looks similar, but that one was already resolved and the compiler does not crash anymore for the input given in that bug report.
The text was updated successfully, but these errors were encountered:
texmex76
added
the
bug
Observed behavior contradicts documented or intended behavior
label
Oct 15, 2024
Still reproduces for me on newer version 0.14.0-dev.1579+f3445f8f6.
FYI, the issue is probably with your union type: Since it has no possible states, it is an uninstantiable type (aka noreturn-like), which aren't valid in arguments to called/instantiated functions. (See also #15909 for planned behavior.)
As you've stated though, the compiler crashing is a bug, it should instead result in a compile error pointing out the problem.
Update: As stated below, apparently there's a separate bug at play. After that it makes sense to re-test whether the compiler still crashes here or correctly reports the error.
Zig Version
0.13.0
Steps to Reproduce and Observed Behavior
When trying to build the above code using
zig build-exe
, the compiler segfaults:Expected Behavior
Expected the compiler to give any output and exit gracefully.
I looked a bit around and 18518 looks similar, but that one was already resolved and the compiler does not crash anymore for the input given in that bug report.
The text was updated successfully, but these errors were encountered: