summaryrefslogtreecommitdiff
path: root/typing/typetexp.ml
diff options
context:
space:
mode:
Diffstat (limited to 'typing/typetexp.ml')
-rw-r--r--typing/typetexp.ml9
1 files changed, 7 insertions, 2 deletions
diff --git a/typing/typetexp.ml b/typing/typetexp.ml
index 560bcec735..79aefb1e6c 100644
--- a/typing/typetexp.ml
+++ b/typing/typetexp.ml
@@ -142,8 +142,13 @@ let find_module env loc lid =
check_deprecated loc decl.md_attributes (Path.name path);
r
-let find_modtype =
- find_component Env.lookup_modtype (fun lid -> Unbound_modtype lid)
+let find_modtype env loc lid =
+ let (path, decl) as r =
+ find_component Env.lookup_modtype (fun lid -> Unbound_modtype lid)
+ env loc lid
+ in
+ check_deprecated loc decl.mtd_attributes (Path.name path);
+ r
let find_class_type env loc lid =
let (path, decl) as r =