File tree Expand file tree Collapse file tree 2 files changed +9
-9
lines changed Expand file tree Collapse file tree 2 files changed +9
-9
lines changed Original file line number Diff line number Diff line change @@ -163,9 +163,12 @@ function caml_binaryen_clear_pass_arguments() {
163163//Provides: caml_binaryen_has_pass_to_skip
164164//Requires: Binaryen
165165//Requires: caml_jsstring_of_string
166+ //Requires: caml_js_to_bool
166167function caml_binaryen_has_pass_to_skip ( pass ) {
167- return Binaryen . hasPassToSkip (
168- caml_jsstring_of_string ( pass )
168+ return caml_js_to_bool (
169+ Binaryen . hasPassToSkip (
170+ caml_jsstring_of_string ( pass )
171+ )
169172 ) ;
170173}
171174
Original file line number Diff line number Diff line change @@ -55,14 +55,11 @@ let _ = assert (Settings.get_optimize_stack_ir () == true)
5555let _ = Settings. set_optimize_stack_ir false
5656
5757(* Testing pass_argument *)
58+ let _ = assert (Settings. get_pass_argument " theKey" = None )
5859let _ = Settings. set_pass_argument " theKey" " theValue"
59- let _ = Settings. get_pass_argument " theKey" = " theValue"
60- let _ = Settings. set_pass_argument " theKey" " theValue2"
61- let _ = Settings. get_pass_argument " theKey" = " theValue2"
62-
63- let _ =
64- Settings. clear_pass_arguments
65- () (* Note: there is no way to test this currently *)
60+ let _ = assert (Settings. get_pass_argument " theKey" = Some " theValue" )
61+ let _ = Settings. clear_pass_arguments ()
62+ let _ = assert (Settings. get_pass_argument " theKey" = None )
6663
6764(* Testing skip_pass *)
6865let _ = assert (Settings. has_pass_to_skip " thePass" == false )
You can’t perform that action at this time.
0 commit comments