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
@Skytrias does this really break at runtime? I'm not even able to compile it. The compiler fails on that assertion.
No binary is produced when I run it over here.
System info
OS Name: Microsoft Windows 10 Enterprise
OS Version: 10.0.18363 N/A Build 18363
OS Manufacturer: Microsoft Corporation
Odin version: dev-2021-09:461ca408
In any case, maybe empty unions should be disallowed entirely? I'm not sure I see the case for allowing it at all.
This should probably be a semantic analysis check to fail even before code gen starts.
@gingerBill is allowing empty unions something intended? 🤔
I am marking this issue as stale as it has not received any engagement from the community or maintainers 120 days. That does not imply that the issue has no merit! If you feel strongly about this issue
open a PR referencing and resolving the issue;
leave a comment on it and discuss ideas how you could contribute towards resolving it;
leave a comment and describe in detail why this issue is critical for your use case;
open a new issue with updated details and a plan on resolving the issue.
The motivation for this automation is to help prioritize issues in the backlog and not ignore, reject, or belittle anyone..
Context
Linux Mint 20 - Kernel 5.4.0-73-generic
odin version
output:odin version dev-2021-08:7b2f6aaa
Expected Behavior
Compilation should be disallowed when
switch
ing on an empty union.Current Behavior
Compiles, but asserts at runtime / startup.
Failure Information (for bugs)
src/llvm_backend_general.cpp(1108): Assertion Failure: type_size_of(ut) > 0
Steps to Reproduce
The text was updated successfully, but these errors were encountered: