File tree Expand file tree Collapse file tree 4 files changed +24
-0
lines changed Expand file tree Collapse file tree 4 files changed +24
-0
lines changed Original file line number Diff line number Diff line change 2020
2121- Remove unnecessary require and import statements when using dynamic imports. https://github.com/rescript-lang/rescript-compiler/pull/6232
2222- Fix option unboxing logic in the presence of untagged variants. https://github.com/rescript-lang/rescript-compiler/pull/6233
23+ - Fix printing of local module with type. https://github.com/rescript-lang/rescript-compiler/issues/6212
2324
2425#### :nail_care : Polish
2526
Original file line number Diff line number Diff line change @@ -4965,6 +4965,15 @@ and printExpressionBlock ~state ~braces expr cmtTbl =
49654965 let doc = Doc. text modName.txt in
49664966 printComments doc cmtTbl modName.loc
49674967 in
4968+ let name, modExpr =
4969+ match modExpr.pmod_desc with
4970+ | Pmod_constraint (modExpr , modType ) ->
4971+ let name =
4972+ Doc. concat [name; Doc. text " : " ; printModType ~state modType cmtTbl]
4973+ in
4974+ (name, modExpr)
4975+ | _ -> (name, modExpr)
4976+ in
49684977 let letModuleDoc =
49694978 Doc. concat
49704979 [
Original file line number Diff line number Diff line change @@ -15,3 +15,10 @@ module Empty = {/* test */}
1515module EmptyModule = {
1616 /* TODO: management on vacation */
1717}
18+
19+ module type T = {}
20+
21+ let g = {
22+ module M: T = {}
23+ 0
24+ }
Original file line number Diff line number Diff line change @@ -15,3 +15,10 @@ module Empty = {/* test */}
1515module EmptyModule = {
1616 /* TODO: management on vacation */
1717}
18+
19+ module type T = {}
20+
21+ let g = {
22+ module M : T = {}
23+ 0
24+ }
You can’t perform that action at this time.
0 commit comments