Added an extra check in trans_alt
Gratuitous right now, but I'm going to change the type of trans::type_of
This commit is contained in:
parent
f41f75fe53
commit
2c6eba00dd
1 changed files with 1 additions and 0 deletions
|
@ -576,6 +576,7 @@ fn bind_irrefutable_pat(bcx: @block_ctxt, pat: @ast::pat, val: ValueRef,
|
||||||
// FIXME: Could constrain pat_bind to make this
|
// FIXME: Could constrain pat_bind to make this
|
||||||
// check unnecessary.
|
// check unnecessary.
|
||||||
check (type_has_static_size(ccx, ty));
|
check (type_has_static_size(ccx, ty));
|
||||||
|
check non_ty_var(ccx, ty);
|
||||||
let llty = trans::type_of(ccx, pat.span, ty);
|
let llty = trans::type_of(ccx, pat.span, ty);
|
||||||
let alloc = trans::alloca(bcx, llty);
|
let alloc = trans::alloca(bcx, llty);
|
||||||
bcx =
|
bcx =
|
||||||
|
|
Loading…
Reference in a new issue