summaryrefslogtreecommitdiffstats
path: root/ocamldoc/odoc_sig.ml
diff options
context:
space:
mode:
Diffstat (limited to 'ocamldoc/odoc_sig.ml')
-rw-r--r--ocamldoc/odoc_sig.ml15
1 files changed, 14 insertions, 1 deletions
diff --git a/ocamldoc/odoc_sig.ml b/ocamldoc/odoc_sig.ml
index 93f0193e5..627938453 100644
--- a/ocamldoc/odoc_sig.ml
+++ b/ocamldoc/odoc_sig.ml
@@ -870,6 +870,8 @@ module Analyser =
let rec f = function
Parsetree.Pmty_ident longident ->
Name.from_longident longident.txt
+ | Parsetree.Pmty_alias longident ->
+ Name.from_longident longident.txt
| Parsetree.Pmty_signature _ ->
"??"
| Parsetree.Pmty_functor _ ->
@@ -1060,6 +1062,16 @@ module Analyser =
Module_type_alias { mta_name = Odoc_env.full_module_type_name env name ;
mta_module = None }
+ | Parsetree.Pmty_alias longident ->
+ let name =
+ match sig_module_type with
+ Types.Mty_alias path -> Name.from_path path
+ | _ -> Name.from_longident longident.txt
+ in
+ (* Wrong naming... *)
+ Module_type_alias { mta_name = Odoc_env.full_module_name env name ;
+ mta_module = None }
+
| Parsetree.Pmty_signature ast ->
(
let ast = filter_out_erased_items_from_signature erased ast in
@@ -1136,7 +1148,8 @@ module Analyser =
and analyse_module_kind
?(erased = Name.Set.empty) env current_module_name module_type sig_module_type =
match module_type.Parsetree.pmty_desc with
- Parsetree.Pmty_ident longident ->
+ Parsetree.Pmty_ident longident
+ | Parsetree.Pmty_alias longident ->
let k = analyse_module_type_kind env current_module_name module_type sig_module_type in
Module_with ( k, "" )