about summary refs log tree commit diff
path: root/src/boot
diff options
context:
space:
mode:
authorGraydon Hoare <graydon@mozilla.com>2010-07-02 12:33:51 -0700
committerGraydon Hoare <graydon@mozilla.com>2010-07-02 12:33:51 -0700
commitf955d06ca9bf424b3de679319b52c4f4a2d65aee (patch)
treec831e060c5bccaf66af181583769dc994f85196f /src/boot
parent0efce5ebe2ffff47dd75ec68edc9dc4857da6c8d (diff)
downloadrust-f955d06ca9bf424b3de679319b52c4f4a2d65aee.tar.gz
rust-f955d06ca9bf424b3de679319b52c4f4a2d65aee.zip
Don't unify the *input* to init-box with a box constraint, nurr.
Diffstat (limited to 'src/boot')
-rw-r--r--src/boot/me/type.ml5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/boot/me/type.ml b/src/boot/me/type.ml
index 5fbb77a40bc..5eec68602d7 100644
--- a/src/boot/me/type.ml
+++ b/src/boot/me/type.ml
@@ -1275,9 +1275,10 @@ 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 = ref (TYSPEC_mutable (ref (TYSPEC_box (any())))) in
+            let in_tv = any() in
+            let tv = ref (TYSPEC_mutable (ref (TYSPEC_box in_tv))) in
               unify_lval strict_ctx dst tv;
-              unify_atom rval_ctx v tv;
+              unify_atom rval_ctx v in_tv;
 
         (* FIXME (issue #52): Finish these. *)
         (* Fake-typecheck a few comm-related statements for now, just enough