aboutsummaryrefslogtreecommitdiff
path: root/src/boot
diff options
context:
space:
mode:
authorGraydon Hoare <[email protected]>2010-07-01 18:39:08 -0700
committerGraydon Hoare <[email protected]>2010-07-01 18:39:08 -0700
commitc27879a1aac0d623c857697cf7deccc8e9c39e78 (patch)
treeda75f613f39192b92b1d1e56f4cea8f16dbd7fd2 /src/boot
parentClarify in type logging when we have a constraint vs. a resolved type. (diff)
downloadrust-c27879a1aac0d623c857697cf7deccc8e9c39e78.tar.xz
rust-c27879a1aac0d623c857697cf7deccc8e9c39e78.zip
Of course, the LHS constraint on an init-box statement is mutable @.
Diffstat (limited to 'src/boot')
-rw-r--r--src/boot/me/type.ml4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/boot/me/type.ml b/src/boot/me/type.ml
index 2ec35f75..c0251d4a 100644
--- a/src/boot/me/type.ml
+++ b/src/boot/me/type.ml
@@ -1279,8 +1279,8 @@ let process_crate (cx:ctxt) (crate:Ast.crate) : unit =
unify_lval rval_ctx lval (ty Ast.TY_task);
| Ast.STMT_init_box (dst, v) ->
- let tv = any() in
- unify_lval init_ctx dst (ref (TYSPEC_box tv));
+ let tv = ref (TYSPEC_mutable (ref (TYSPEC_box (any())))) in
+ unify_lval strict_ctx dst tv;
unify_atom rval_ctx v tv;
(* FIXME (issue #52): Finish these. *)