@@ -39,16 +39,16 @@ let trim_trailing_dir_sep s =
3939
4040let normalize_include_dirs dirs = List. map dirs ~f: trim_trailing_dir_sep
4141
42- let normalize_effects (effects : [ `Cps | `Double_translation ] option ) common :
43- Config. effects_backend =
42+ let normalize_effects (effects : [ `Disabled | ` Cps | `Double_translation ] option ) common
43+ : Config.effects_backend =
4444 match effects with
4545 | None ->
4646 (* For backward compatibility, consider that [--enable effects] alone means
4747 [--effects cps] *)
4848 if List. mem ~eq: String. equal " effects" common.Jsoo_cmdline.Arg. optim.enable
4949 then `Cps
5050 else `Disabled
51- | Some ((`Cps | `Double_translation ) as e ) -> (e :> Config.effects_backend )
51+ | Some ((`Disabled | ` Cps | `Double_translation ) as e ) -> e
5252
5353type t =
5454 { common : Jsoo_cmdline.Arg .t
@@ -273,12 +273,20 @@ let options =
273273 in
274274 let effects =
275275 let doc =
276- " Select an implementation of effect handlers. [$(docv)] should be one of $(b,cps) \
277- or $(b,double-translation). Effects won't be supported if unspecified."
276+ " Select an implementation of effect handlers. [$(docv)] should be one of $(b,cps), \
277+ $(b,double-translation) or $(b,disabled) (the default). Effects won't be \
278+ supported if unspecified."
278279 in
279280 Arg. (
280281 value
281- & opt (some (enum [ " cps" , `Cps ; " double-translation" , `Double_translation ])) None
282+ & opt
283+ (some
284+ (enum
285+ [ " cps" , `Cps
286+ ; " double-translation" , `Double_translation
287+ ; " disabled" , `Disabled
288+ ]))
289+ None
282290 & info [ " effects" ] ~docv: " KIND" ~doc )
283291 in
284292 let build_t
@@ -543,12 +551,20 @@ let options_runtime_only =
543551 in
544552 let effects =
545553 let doc =
546- " Select an implementation of effect handlers. [$(docv)] should be one of $(b,cps) \
547- or $(b,double-translation). Effects won't be supported if unspecified."
554+ " Select an implementation of effect handlers. [$(docv)] should be one of $(b,cps), \
555+ $(b,double-translation), or $(b,disabled) (the default). Effects won't be \
556+ supported if unspecified."
548557 in
549558 Arg. (
550559 value
551- & opt (some (enum [ " cps" , `Cps ; " double-translation" , `Double_translation ])) None
560+ & opt
561+ (some
562+ (enum
563+ [ " cps" , `Cps
564+ ; " double-translation" , `Double_translation
565+ ; " disabled" , `Disabled
566+ ]))
567+ None
552568 & info [ " effects" ] ~docv: " KIND" ~doc )
553569 in
554570 let build_t
0 commit comments