Skip to content

Commit 960bf54

Browse files
committed
add Clflags.bs_gentype
1 parent 602e8d6 commit 960bf54

File tree

3 files changed

+5
-3
lines changed

3 files changed

+5
-3
lines changed

typing/cmt_format.ml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -236,8 +236,8 @@ let save_cmt filename modname binary_annots sourcefile initial_env sg =
236236
output_cmt oc cmt;
237237
close_out oc;
238238
(* TODO: does not make sense to do post-proccesing for [Partial_implementaiton]*)
239-
match Sys.getenv "BS_CMT_POST_PROCESS_CMD" with
240-
| exception _ -> ()
241-
| cmd -> ignore (Sys.command (cmd ^ " -cmt-add " ^ filename ^ (match sourcefile with None -> "" | Some sourcefile -> ":" ^ sourcefile)))
239+
match !Clflags.bs_gentype with
240+
| None -> ()
241+
| Some cmd -> ignore (Sys.command (cmd ^ " -cmt-add " ^ filename ^ (match sourcefile with None -> "" | Some sourcefile -> ":" ^ sourcefile)))
242242
end;
243243
clear ()

utils/clflags.ml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -127,6 +127,7 @@ let bs_vscode =
127127
*)
128128
let dont_record_crc_unit : string option ref = ref None
129129
let bs_only = ref false
130+
let bs_gentype = ref None
130131
let no_assert_false = ref false
131132
#end
132133

utils/clflags.mli

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -107,6 +107,7 @@ val record_event_when_debug : bool ref
107107
val bs_vscode : bool
108108
val dont_record_crc_unit : string option ref
109109
val bs_only : bool ref (* set true on bs top*)
110+
val bs_gentype : string option ref
110111
val no_assert_false : bool ref
111112
#end
112113

0 commit comments

Comments
 (0)