Skip to content
Snippets Groups Projects
Commit 332c8504 authored by Thomas Wood's avatar Thomas Wood
Browse files

Module application support

parent 585385c1
No related branches found
No related tags found
No related merge requests found
...@@ -198,6 +198,9 @@ let ppf_ident_name = ...@@ -198,6 +198,9 @@ let ppf_ident_name =
let ppf_ident i = let ppf_ident i =
i |> Ident.name |> ppf_ident_name i |> Ident.name |> ppf_ident_name
let ppf_path =
Path.name
let ppf_module content = let ppf_module content =
Printf.sprintf "{@,%s@,}" content Printf.sprintf "{@,%s@,}" content
...@@ -217,8 +220,8 @@ and js_of_submodule m = ...@@ -217,8 +220,8 @@ and js_of_submodule m =
match m.mod_desc with match m.mod_desc with
| Tmod_structure s -> ppf_module (js_of_structure s) | Tmod_structure s -> ppf_module (js_of_structure s)
| Tmod_functor (id, _, mtyp, mexp) -> ppf_function (ppf_ident id) (js_of_submodule mexp) | Tmod_functor (id, _, mtyp, mexp) -> ppf_function (ppf_ident id) (js_of_submodule mexp)
| Tmod_ident _ -> out_of_scope loc "module ident" | Tmod_apply (m1, m2, _) -> ppf_apply (js_of_submodule m1) (js_of_submodule m2)
| Tmod_apply _ -> out_of_scope loc "module apply" | Tmod_ident (p,_) -> ppf_path p
| Tmod_constraint _ -> out_of_scope loc "module constraint" | Tmod_constraint _ -> out_of_scope loc "module constraint"
| Tmod_unpack _ -> out_of_scope loc "module unpack" | Tmod_unpack _ -> out_of_scope loc "module unpack"
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment