aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorGraydon Hoare <[email protected]>2010-09-23 17:11:30 -0700
committerGraydon Hoare <[email protected]>2010-09-23 17:11:30 -0700
commitbba4cae1b8b6422a4d9569c7b84139c53834b4eb (patch)
treed9012230958a3f582a7c6a81614c41375190f331 /src
parentTranslate a bunch of the material (lltrans, llasm, abi) from rustboot to rust... (diff)
downloadrust-bba4cae1b8b6422a4d9569c7b84139c53834b4eb.tar.xz
rust-bba4cae1b8b6422a4d9569c7b84139c53834b4eb.zip
Resolve constant types through to their definitions.
Diffstat (limited to 'src')
-rw-r--r--src/boot/me/type.ml4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/boot/me/type.ml b/src/boot/me/type.ml
index 2e275537..3e6c2352 100644
--- a/src/boot/me/type.ml
+++ b/src/boot/me/type.ml
@@ -295,7 +295,9 @@ let check_stmt (cx:Semant.ctxt) : (fn_ctx -> Ast.stmt -> unit) =
LTYPE_mono ty
else
LTYPE_poly ((Array.map (fun p -> p.Common.node) params), ty)
- | Ast.MOD_ITEM_const (ty, _) -> LTYPE_mono ty
+ | Ast.MOD_ITEM_const _ ->
+ let ty = Hashtbl.find cx.Semant.ctxt_all_item_types mid_id in
+ LTYPE_mono ty
| Ast.MOD_ITEM_type _ ->
Common.err None "Type-item used in non-type context"
in