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
const assert = @import("std").debug.assert; const Wrapper = struct { T: type }; fn wrap(comptime T: type) -> Wrapper { Wrapper { .T = T } } pub fn main() -> %void { const ty = wrap(i32).T; assert(ty == i32); // this works: // vvvvvvvvvvv //const ty = (Wrapper { .T = i32 }).T; //assert(ty == i32); }
fails during compilation with
zig: /home/scurest/zig/src/codegen.cpp:4178: LLVMOpaqueValue* build_alloca(CodeGen*, TypeTableEntry*, const char*, uint32_t): Assertion `alignment > 0' failed. Aborted (core dumped)
The text was updated successfully, but these errors were encountered:
31aefa6
No branches or pull requests
fails during compilation with
The text was updated successfully, but these errors were encountered: