aboutsummaryrefslogtreecommitdiff
path: root/src/boot/me/resolve.ml
diff options
context:
space:
mode:
Diffstat (limited to 'src/boot/me/resolve.ml')
-rw-r--r--src/boot/me/resolve.ml12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/boot/me/resolve.ml b/src/boot/me/resolve.ml
index 78d372d5..8372b64a 100644
--- a/src/boot/me/resolve.ml
+++ b/src/boot/me/resolve.ml
@@ -877,6 +877,18 @@ let process_crate
(* Post-resolve, we can establish a tag cache. *)
cx.ctxt_tag_cache <- Some (Hashtbl.create 0);
cx.ctxt_rebuild_cache <- Some (Hashtbl.create 0);
+
+ (* Also index all the type names for future error messages. *)
+ Hashtbl.iter
+ begin
+ fun item_id ty ->
+ let item_names = cx.Semant.ctxt_all_item_names in
+ if Hashtbl.mem item_names item_id then
+ Hashtbl.add cx.Semant.ctxt_user_type_names ty
+ (Hashtbl.find item_names item_id)
+ end
+ cx.Semant.ctxt_all_type_items;
+
;;
(*