New issue

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

compiler crash on var typed struct member #779

tgschultz opened this Issue Feb 18, 2018 · 1 comment


None yet
2 participants

tgschultz commented Feb 18, 2018

const warn = @import("std").debug.warn;
test "var typed struct member"
   var s = (struct{v: var}){.v=i32(10)};

@andrewrk andrewrk added this to the 0.2.0 milestone Feb 18, 2018

@andrewrk andrewrk added the bug label Feb 18, 2018


This comment has been minimized.


andrewrk commented Feb 18, 2018

Correct behavior is a parse error. var as a type is only allowed for function parameters and return value

@andrewrk andrewrk closed this in eff3530 Mar 6, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment