@@ -134,15 +134,15 @@ let rec forTypeSignatureItem ~env ~(exported : SharedTypes.exported)
134
134
| Sig_module (ident , {md_type; md_attributes; md_loc} , _ ) ->
135
135
let declared =
136
136
addItem ~extent: md_loc
137
- ~item: (forModuleType env md_type)
137
+ ~item: (forTypeModule env md_type)
138
138
~name: (Location. mknoloc (Ident. name ident))
139
139
~stamp: (Ident. binding_time ident) ~env md_attributes exported.modules
140
140
env.stamps.modules
141
141
in
142
142
[{declared with item = Module declared.item}]
143
143
| _ -> []
144
144
145
- and forSignatureType env signature =
145
+ and forTypeSignature env signature =
146
146
let exported = initExported () in
147
147
let topLevel =
148
148
List. fold_right
@@ -151,13 +151,13 @@ and forSignatureType env signature =
151
151
in
152
152
{docstring = [] ; exported; topLevel}
153
153
154
- and forModuleType env moduleType =
154
+ and forTypeModule env moduleType =
155
155
match moduleType with
156
156
| Types. Mty_ident path -> Ident path
157
157
| Mty_alias (_ (* 402 *) , path ) -> Ident path
158
- | Mty_signature signature -> Structure (forSignatureType env signature)
158
+ | Mty_signature signature -> Structure (forTypeSignature env signature)
159
159
| Mty_functor (_argIdent , _argType , resultType ) ->
160
- forModuleType env resultType
160
+ forTypeModule env resultType
161
161
162
162
let getModuleTypePath mod_desc =
163
163
match mod_desc with
@@ -246,7 +246,7 @@ let forSignatureItem ~env ~(exported : exported)
246
246
decl |> forTypeDeclaration ~env ~exported ~rec Status)
247
247
| Tsig_module
248
248
{md_id; md_attributes; md_loc; md_name = name; md_type = {mty_type}} ->
249
- let item = forModuleType env mty_type in
249
+ let item = forTypeModule env mty_type in
250
250
let declared =
251
251
addItem ~item ~name ~extent: md_loc ~stamp: (Ident. binding_time md_id) ~env
252
252
md_attributes exported.modules env.stamps.modules
@@ -350,7 +350,7 @@ let rec forItem ~env ~(exported : exported) item =
350
350
let env =
351
351
{env with modulePath = ExportedModule (name.txt, env.modulePath)}
352
352
in
353
- let modTypeItem = forModuleType env modType in
353
+ let modTypeItem = forTypeModule env modType in
354
354
let declared =
355
355
addItem ~item: modTypeItem ~name ~extent: mtd_loc
356
356
~stamp: (Ident. binding_time mtd_id)
@@ -430,14 +430,14 @@ and forModule env mod_desc moduleName =
430
430
let env =
431
431
{env with modulePath = ExportedModule (moduleName, env.modulePath)}
432
432
in
433
- forModuleType env moduleType
433
+ forTypeModule env moduleType
434
434
| Tmod_constraint (expr , typ , _constraint , _coercion ) ->
435
435
(* TODO do this better I think *)
436
436
let modKind = forModule env expr.mod_desc moduleName in
437
437
let env =
438
438
{env with modulePath = ExportedModule (moduleName, env.modulePath)}
439
439
in
440
- let modTypeKind = forModuleType env typ in
440
+ let modTypeKind = forTypeModule env typ in
441
441
Constraint (modKind, modTypeKind)
442
442
443
443
and forStructure ~env items =
0 commit comments