diff --git a/compiler/tests-ocaml/lib-effects/marshal.ml b/compiler/tests-ocaml/lib-effects/marshal.ml index 8788272372..6c754073e2 100644 --- a/compiler/tests-ocaml/lib-effects/marshal.ml +++ b/compiler/tests-ocaml/lib-effects/marshal.ml @@ -12,9 +12,10 @@ let _ = Some (fun k -> (* We have to make sure that neither the match nor the call to Marshal.to_string are eliminated, so we call - print_string and we return the result of the marshalling + print_string and we print the result of the marshalling function. *) - match print_string ""; Stdlib.Marshal.to_string k [] with - | x -> x - | exception ((*Invalid_argument*) _) -> print_endline "ok"; "" + match print_string ""; + Stdlib.Marshal.to_string k [] with + | x -> Printf.printf "%S" x; assert false + | exception (Invalid_argument _) -> print_endline "ok"; "" ) } diff --git a/compiler/tests-ocaml/lib-effects/marshal.reference b/compiler/tests-ocaml/lib-effects/marshal.reference index a640b98b37..9766475a41 100644 --- a/compiler/tests-ocaml/lib-effects/marshal.reference +++ b/compiler/tests-ocaml/lib-effects/marshal.reference @@ -1 +1 @@ -Aok +ok