diff options
author | Damien Doligez <damien.doligez@inria.fr> | 2023-04-25 15:25:52 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-04-25 16:25:52 +0200 |
commit | 0a7c5fe35f4be2ea5c834b586fb5e947bd952377 (patch) | |
tree | 0d66e63cda683098b81ef07f2dad09e9a9c85477 /testsuite/tests | |
parent | 6be361ffd75a2fce5f4daa21fd5073b9a18ce31c (diff) | |
download | ocaml-0a7c5fe35f4be2ea5c834b586fb5e947bd952377.tar.gz |
New script language for ocamltest (#12185)
New test script language, all tests translated automatically (see `tools/translate-all-tests`).
Diffstat (limited to 'testsuite/tests')
1220 files changed, 8032 insertions, 6611 deletions
diff --git a/testsuite/tests/afl-instrumentation/afl-fuzz-test.ml b/testsuite/tests/afl-instrumentation/afl-fuzz-test.ml index 8547b388a3..4880f613a8 100644 --- a/testsuite/tests/afl-instrumentation/afl-fuzz-test.ml +++ b/testsuite/tests/afl-instrumentation/afl-fuzz-test.ml @@ -1,12 +1,14 @@ -(* TEST (* Just a test-driver *) - * native-compiler - ** script - script = "sh ${test_source_directory}/has-afl-fuzz.sh" - readonly_files = "readline.ml" - *** setup-ocamlopt.byte-build-env - **** ocamlopt.byte - program = "${test_build_directory}/readline" - flags = "-afl-instrument" - all_modules = "readline.ml" - ***** run +(* TEST + native-compiler; + script = "sh ${test_source_directory}/has-afl-fuzz.sh"; + readonly_files = "readline.ml"; + script; + setup-ocamlopt.byte-build-env; + program = "${test_build_directory}/readline"; + flags = "-afl-instrument"; + all_modules = "readline.ml"; + ocamlopt.byte; + run; *) + +(* No code here, this file is a pure test script. *) diff --git a/testsuite/tests/afl-instrumentation/afl-showmap-test.ml b/testsuite/tests/afl-instrumentation/afl-showmap-test.ml index 5efc626874..d63739a4fc 100644 --- a/testsuite/tests/afl-instrumentation/afl-showmap-test.ml +++ b/testsuite/tests/afl-instrumentation/afl-showmap-test.ml @@ -1,16 +1,18 @@ -(* TEST (* Just a test-driver *) - * native-compiler - ** script - script = "sh ${test_source_directory}/has-afl-showmap.sh" - readonly_files = "harness.ml test.ml" - *** setup-ocamlopt.byte-build-env - **** ocamlopt.byte - module = "test.ml" - flags = "-afl-instrument" - ***** ocamlopt.byte - module = "" - program = "${test_build_directory}/test" - flags = "-afl-inst-ratio 0" - all_modules = "test.cmx harness.ml" - ****** run +(* TEST + native-compiler; + script = "sh ${test_source_directory}/has-afl-showmap.sh"; + readonly_files = "harness.ml test.ml"; + script; + setup-ocamlopt.byte-build-env; + module = "test.ml"; + flags = "-afl-instrument"; + ocamlopt.byte; + module = ""; + program = "${test_build_directory}/test"; + flags = "-afl-inst-ratio 0"; + all_modules = "test.cmx harness.ml"; + ocamlopt.byte; + run; *) + +(* No code here, this file is a pure test script. *) diff --git a/testsuite/tests/arch-power/exn_raise.ml b/testsuite/tests/arch-power/exn_raise.ml index a68eb875ed..1ed4622f43 100644 --- a/testsuite/tests/arch-power/exn_raise.ml +++ b/testsuite/tests/arch-power/exn_raise.ml @@ -1,9 +1,9 @@ (* TEST - * arch_power - ** native - *** ocamlopt.byte - ocamlopt_flags = "-flarge-toc" - **** run + arch_power; + native; + ocamlopt_flags = "-flarge-toc"; + ocamlopt.byte; + run; *) (* GPR#8506 diff --git a/testsuite/tests/asmcomp/bind_tuples.ml b/testsuite/tests/asmcomp/bind_tuples.ml index 156b08721e..384965b428 100644 --- a/testsuite/tests/asmcomp/bind_tuples.ml +++ b/testsuite/tests/asmcomp/bind_tuples.ml @@ -1,5 +1,5 @@ (* TEST - * native + native; *) (* Check the effectiveness of optimized compilation of tuple binding diff --git a/testsuite/tests/asmcomp/compare.ml b/testsuite/tests/asmcomp/compare.ml index b51116e372..1a14c4dd32 100644 --- a/testsuite/tests/asmcomp/compare.ml +++ b/testsuite/tests/asmcomp/compare.ml @@ -1,5 +1,5 @@ (* TEST - * native + native; *) let[@inline never] float () = print_string "hello\n"; 42. let[@inline never] f () = compare (float ()) 0.5;; diff --git a/testsuite/tests/asmcomp/evaluation_order.ml b/testsuite/tests/asmcomp/evaluation_order.ml index 2fb7f917ff..f9cce72ef5 100644 --- a/testsuite/tests/asmcomp/evaluation_order.ml +++ b/testsuite/tests/asmcomp/evaluation_order.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) external unsafe_get : 'a array -> int -> 'a = "%array_unsafe_get" external caml_bytes_get_16 : bytes -> int -> int = "%caml_bytes_get16" external caml_bytes_set_16 : bytes -> int -> int -> unit = "%caml_bytes_set16" diff --git a/testsuite/tests/asmcomp/func_sections.ml b/testsuite/tests/asmcomp/func_sections.ml index 7a58afc60c..bdfcaf4529 100644 --- a/testsuite/tests/asmcomp/func_sections.ml +++ b/testsuite/tests/asmcomp/func_sections.ml @@ -1,18 +1,23 @@ (* TEST -* function_sections -flags = "-S -function-sections" -** arch_arm -*** native -reference = "${test_source_directory}/func_sections.arm.reference" -** arch_arm64 -*** native -reference = "${test_source_directory}/func_sections.arm.reference" -** arch_amd64 -*** native -reference = "${test_source_directory}/func_sections.reference" -** arch_i386 -*** native -reference = "${test_source_directory}/func_sections.reference" + flags = "-S -function-sections"; + function_sections; + { + arch_arm; + reference = "${test_source_directory}/func_sections.arm.reference"; + native; + }{ + arch_arm64; + reference = "${test_source_directory}/func_sections.arm.reference"; + native; + }{ + arch_amd64; + reference = "${test_source_directory}/func_sections.reference"; + native; + }{ + arch_i386; + reference = "${test_source_directory}/func_sections.reference"; + native; + } *) (* We have a separate reference output for ARM because diff --git a/testsuite/tests/asmcomp/lift_mutable_let_flambda.ml b/testsuite/tests/asmcomp/lift_mutable_let_flambda.ml index 8c8b017d49..7f2758ef94 100644 --- a/testsuite/tests/asmcomp/lift_mutable_let_flambda.ml +++ b/testsuite/tests/asmcomp/lift_mutable_let_flambda.ml @@ -1,6 +1,6 @@ (* TEST - * flambda - ** native + flambda; + native; *) type t = T of { pos : int } diff --git a/testsuite/tests/asmcomp/optargs.ml b/testsuite/tests/asmcomp/optargs.ml index 65e4152bf2..32aafd48e0 100644 --- a/testsuite/tests/asmcomp/optargs.ml +++ b/testsuite/tests/asmcomp/optargs.ml @@ -1,6 +1,6 @@ (* TEST - flags = "-g" - * native + flags = "-g"; + native; *) (* Check the effectiveness of inlining the wrapper which fills in diff --git a/testsuite/tests/asmcomp/poll_attr_both.ml b/testsuite/tests/asmcomp/poll_attr_both.ml index d67d2fd973..56f6fe4a7f 100644 --- a/testsuite/tests/asmcomp/poll_attr_both.ml +++ b/testsuite/tests/asmcomp/poll_attr_both.ml @@ -1,13 +1,13 @@ -(* TEST - * setup-ocamlopt.byte-build-env - ** ocamlopt.byte -ocamlopt_byte_exit_status = "2" - *** check-ocamlopt.byte-output - - * setup-ocamlopt.opt-build-env - ** ocamlopt.opt -ocamlopt_opt_exit_status = "2" - *** check-ocamlopt.opt-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + + + + + *) let[@inline never][@local never] v x = x + 1 @@ -19,3 +19,17 @@ let[@poll error] c x = ignore(Sys.opaque_identity(42)) done; x2 + !y + +(* TEST + { + setup-ocamlopt.byte-build-env; + ocamlopt_byte_exit_status = "2"; + ocamlopt.byte; + check-ocamlopt.byte-output; + }{ + setup-ocamlopt.opt-build-env; + ocamlopt_opt_exit_status = "2"; + ocamlopt.opt; + check-ocamlopt.opt-output; + } +*) diff --git a/testsuite/tests/asmcomp/poll_attr_inserted.ml b/testsuite/tests/asmcomp/poll_attr_inserted.ml index 0ea17755b7..2738fe4558 100644 --- a/testsuite/tests/asmcomp/poll_attr_inserted.ml +++ b/testsuite/tests/asmcomp/poll_attr_inserted.ml @@ -1,13 +1,15 @@ (* TEST - * setup-ocamlopt.byte-build-env - ** ocamlopt.byte -ocamlopt_byte_exit_status = "2" - *** check-ocamlopt.byte-output - - * setup-ocamlopt.opt-build-env - ** ocamlopt.opt -ocamlopt_opt_exit_status = "2" - *** check-ocamlopt.opt-output + { + setup-ocamlopt.byte-build-env; + ocamlopt_byte_exit_status = "2"; + ocamlopt.byte; + check-ocamlopt.byte-output; + }{ + setup-ocamlopt.opt-build-env; + ocamlopt_opt_exit_status = "2"; + ocamlopt.opt; + check-ocamlopt.opt-output; + } *) let[@poll error] c x = diff --git a/testsuite/tests/asmcomp/poll_attr_prologue.ml b/testsuite/tests/asmcomp/poll_attr_prologue.ml index 41b3f6b92f..4e32b79f40 100644 --- a/testsuite/tests/asmcomp/poll_attr_prologue.ml +++ b/testsuite/tests/asmcomp/poll_attr_prologue.ml @@ -1,16 +1,30 @@ -(* TEST - * setup-ocamlopt.byte-build-env - ** ocamlopt.byte -ocamlopt_byte_exit_status = "2" - *** check-ocamlopt.byte-output - - * setup-ocamlopt.opt-build-env - ** ocamlopt.opt -ocamlopt_opt_exit_status = "2" - *** check-ocamlopt.opt-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + + + + + *) let[@poll error] rec c x l = match l with | [] -> 0 | _ :: tl -> (c[@tailcall]) (x+1) tl + +(* TEST + { + setup-ocamlopt.byte-build-env; + ocamlopt_byte_exit_status = "2"; + ocamlopt.byte; + check-ocamlopt.byte-output; + }{ + setup-ocamlopt.opt-build-env; + ocamlopt_opt_exit_status = "2"; + ocamlopt.opt; + check-ocamlopt.opt-output; + } +*) diff --git a/testsuite/tests/asmcomp/poll_attr_user.ml b/testsuite/tests/asmcomp/poll_attr_user.ml index e807bd60d4..9b68489f26 100644 --- a/testsuite/tests/asmcomp/poll_attr_user.ml +++ b/testsuite/tests/asmcomp/poll_attr_user.ml @@ -1,13 +1,13 @@ -(* TEST - * setup-ocamlopt.byte-build-env - ** ocamlopt.byte -ocamlopt_byte_exit_status = "2" - *** check-ocamlopt.byte-output - - * setup-ocamlopt.opt-build-env - ** ocamlopt.opt -ocamlopt_opt_exit_status = "2" - *** check-ocamlopt.opt-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + + + + + *) let[@inline never][@local never] v x = x + 1 @@ -19,3 +19,17 @@ let[@poll error] c x = ignore(Sys.opaque_identity(ref 42)) done; x2 + !y + +(* TEST + { + setup-ocamlopt.byte-build-env; + ocamlopt_byte_exit_status = "2"; + ocamlopt.byte; + check-ocamlopt.byte-output; + }{ + setup-ocamlopt.opt-build-env; + ocamlopt_opt_exit_status = "2"; + ocamlopt.opt; + check-ocamlopt.opt-output; + } +*) diff --git a/testsuite/tests/asmcomp/polling_insertion.ml b/testsuite/tests/asmcomp/polling_insertion.ml index f19ae93293..9574ddbe57 100644 --- a/testsuite/tests/asmcomp/polling_insertion.ml +++ b/testsuite/tests/asmcomp/polling_insertion.ml @@ -1,8 +1,8 @@ (* TEST - modules = "polling.c" - compare_programs = "false" - * arch64 - ** native + modules = "polling.c"; + compare_programs = "false"; + arch64; + native; *) (* This set of tests examine poll insertion behaviour. We do this by requesting diff --git a/testsuite/tests/asmcomp/prevent_fma.ml b/testsuite/tests/asmcomp/prevent_fma.ml index 6ce124fce0..79506c9c88 100644 --- a/testsuite/tests/asmcomp/prevent_fma.ml +++ b/testsuite/tests/asmcomp/prevent_fma.ml @@ -1,5 +1,5 @@ (* TEST - * native + native; *) let ( *. ) x y = Sys.opaque_identity (x *. y) diff --git a/testsuite/tests/asmcomp/register_typing.ml b/testsuite/tests/asmcomp/register_typing.ml index 3bf3104f20..424aa16ab3 100644 --- a/testsuite/tests/asmcomp/register_typing.ml +++ b/testsuite/tests/asmcomp/register_typing.ml @@ -1,5 +1,5 @@ (* TEST - * native + native; *) type 'a typ = Int : int typ | Ptr : int list typ diff --git a/testsuite/tests/asmcomp/register_typing_switch.ml b/testsuite/tests/asmcomp/register_typing_switch.ml index 73960c4bcc..f6a3367d7b 100644 --- a/testsuite/tests/asmcomp/register_typing_switch.ml +++ b/testsuite/tests/asmcomp/register_typing_switch.ml @@ -1,5 +1,5 @@ (* TEST - * native + native; *) type 'a typ = Int : int typ | Ptr : int list typ | Int2 : int typ diff --git a/testsuite/tests/asmcomp/staticalloc.ml b/testsuite/tests/asmcomp/staticalloc.ml index 8f241847f8..38d5587f0f 100644 --- a/testsuite/tests/asmcomp/staticalloc.ml +++ b/testsuite/tests/asmcomp/staticalloc.ml @@ -1,7 +1,7 @@ (* TEST - include config - * native - flags = "config.cmx" + include config; + flags = "config.cmx"; + native; *) (* Check the effectiveness of structured constant propagation and diff --git a/testsuite/tests/asmcomp/unrolling_flambda.ml b/testsuite/tests/asmcomp/unrolling_flambda.ml index dcfcb03303..c7c47b3383 100644 --- a/testsuite/tests/asmcomp/unrolling_flambda.ml +++ b/testsuite/tests/asmcomp/unrolling_flambda.ml @@ -1,6 +1,6 @@ (* TEST - * flambda - ** native + flambda; + native; *) let rec f x = diff --git a/testsuite/tests/asmcomp/unrolling_flambda2.ml b/testsuite/tests/asmcomp/unrolling_flambda2.ml index 3079b7327e..70843c69ec 100644 --- a/testsuite/tests/asmcomp/unrolling_flambda2.ml +++ b/testsuite/tests/asmcomp/unrolling_flambda2.ml @@ -1,6 +1,6 @@ (* TEST - * flambda - ** native + flambda; + native; *) type t = { fn : t -> t -> int -> unit -> unit } diff --git a/testsuite/tests/asmgen/arith.cmm b/testsuite/tests/asmgen/arith.cmm index 3ba0fd333a..464bd96c1c 100644 --- a/testsuite/tests/asmgen/arith.cmm +++ b/testsuite/tests/asmgen/arith.cmm @@ -1,7 +1,7 @@ (* TEST -readonly_files = "mainarith.c" -arguments = "mainarith.c" -* asmgen + readonly_files = "mainarith.c"; + arguments = "mainarith.c"; + asmgen; *) (**************************************************************************) diff --git a/testsuite/tests/asmgen/catch-float.cmm b/testsuite/tests/asmgen/catch-float.cmm index c51eb3c37a..e679a0e291 100644 --- a/testsuite/tests/asmgen/catch-float.cmm +++ b/testsuite/tests/asmgen/catch-float.cmm @@ -1,7 +1,7 @@ (* TEST -readonly_files = "main.c" -arguments = "-DFLOAT_CATCH -DFUN=catch_float main.c" -* asmgen + readonly_files = "main.c"; + arguments = "-DFLOAT_CATCH -DFUN=catch_float main.c"; + asmgen; *) (function "catch_float" (b:int) diff --git a/testsuite/tests/asmgen/catch-multiple.cmm b/testsuite/tests/asmgen/catch-multiple.cmm index 3887c5b891..498235ad72 100644 --- a/testsuite/tests/asmgen/catch-multiple.cmm +++ b/testsuite/tests/asmgen/catch-multiple.cmm @@ -1,7 +1,7 @@ (* TEST -readonly_files = "main.c" -arguments = "-DINT_INT -DFUN=catch_multiple main.c" -* asmgen + readonly_files = "main.c"; + arguments = "-DINT_INT -DFUN=catch_multiple main.c"; + asmgen; *) (* diff --git a/testsuite/tests/asmgen/catch-rec-deadhandler.cmm b/testsuite/tests/asmgen/catch-rec-deadhandler.cmm index 143f880ebc..0eea037a63 100644 --- a/testsuite/tests/asmgen/catch-rec-deadhandler.cmm +++ b/testsuite/tests/asmgen/catch-rec-deadhandler.cmm @@ -1,10 +1,10 @@ (* TEST -flags = "-dlive" -readonly_files = "main.c" -arguments = "-DUNIT_INT -DFUN=catch_rec_deadhandler main.c" -* asmgen -** run -*** check-program-output + flags = "-dlive"; + readonly_files = "main.c"; + arguments = "-DUNIT_INT -DFUN=catch_rec_deadhandler main.c"; + asmgen; + run; + check-program-output; *) (function "catch_rec_deadhandler" () diff --git a/testsuite/tests/asmgen/catch-rec.cmm b/testsuite/tests/asmgen/catch-rec.cmm index 51089d3250..37288f8dab 100644 --- a/testsuite/tests/asmgen/catch-rec.cmm +++ b/testsuite/tests/asmgen/catch-rec.cmm @@ -1,7 +1,7 @@ (* TEST -readonly_files = "main.c" -arguments = "-DINT_INT -DFUN=catch_fact main.c" -* asmgen + readonly_files = "main.c"; + arguments = "-DINT_INT -DFUN=catch_fact main.c"; + asmgen; *) (function "catch_fact" (b:int) diff --git a/testsuite/tests/asmgen/catch-try-float.cmm b/testsuite/tests/asmgen/catch-try-float.cmm index 31df3d3ac5..7aa7234395 100644 --- a/testsuite/tests/asmgen/catch-try-float.cmm +++ b/testsuite/tests/asmgen/catch-try-float.cmm @@ -1,7 +1,7 @@ (* TEST -readonly_files = "main.c" -arguments = "-DFLOAT_CATCH -DFUN=catch_try_float main.c" -* asmgen + readonly_files = "main.c"; + arguments = "-DFLOAT_CATCH -DFUN=catch_try_float main.c"; + asmgen; *) (function "catch_try_float" (b:float) diff --git a/testsuite/tests/asmgen/catch-try.cmm b/testsuite/tests/asmgen/catch-try.cmm index 280a9e17cd..b5253843ed 100644 --- a/testsuite/tests/asmgen/catch-try.cmm +++ b/testsuite/tests/asmgen/catch-try.cmm @@ -1,7 +1,7 @@ (* TEST -readonly_files = "main.c" -arguments = "-DINT_INT -DFUN=catch_exit main.c" -* asmgen + readonly_files = "main.c"; + arguments = "-DINT_INT -DFUN=catch_exit main.c"; + asmgen; *) (function "catch_exit" (b:int) diff --git a/testsuite/tests/asmgen/checkbound.cmm b/testsuite/tests/asmgen/checkbound.cmm index 616c1edc77..a2607b49d2 100644 --- a/testsuite/tests/asmgen/checkbound.cmm +++ b/testsuite/tests/asmgen/checkbound.cmm @@ -1,7 +1,7 @@ (* TEST -readonly_files = "main.c" -arguments = "-DCHECKBOUND main.c" -* asmgen + readonly_files = "main.c"; + arguments = "-DCHECKBOUND main.c"; + asmgen; *) (**************************************************************************) diff --git a/testsuite/tests/asmgen/even-odd-spill-float.cmm b/testsuite/tests/asmgen/even-odd-spill-float.cmm index dc8169b462..a907b71fc2 100644 --- a/testsuite/tests/asmgen/even-odd-spill-float.cmm +++ b/testsuite/tests/asmgen/even-odd-spill-float.cmm @@ -1,7 +1,7 @@ (* TEST -readonly_files = "main.c" -arguments = "-DINT_FLOAT -DFUN=is_even main.c" -* asmgen + readonly_files = "main.c"; + arguments = "-DINT_FLOAT -DFUN=is_even main.c"; + asmgen; *) ("format_odd": string "odd %d\n\000") diff --git a/testsuite/tests/asmgen/even-odd-spill.cmm b/testsuite/tests/asmgen/even-odd-spill.cmm index 9e392445ce..7d3a8040b5 100644 --- a/testsuite/tests/asmgen/even-odd-spill.cmm +++ b/testsuite/tests/asmgen/even-odd-spill.cmm @@ -1,7 +1,7 @@ (* TEST -readonly_files = "main.c" -arguments = "-DINT_INT -DFUN=is_even main.c" -* asmgen + readonly_files = "main.c"; + arguments = "-DINT_INT -DFUN=is_even main.c"; + asmgen; *) ("format_odd": string "odd %d\n\000") diff --git a/testsuite/tests/asmgen/even-odd.cmm b/testsuite/tests/asmgen/even-odd.cmm index a9e20ad894..5143101701 100644 --- a/testsuite/tests/asmgen/even-odd.cmm +++ b/testsuite/tests/asmgen/even-odd.cmm @@ -1,7 +1,7 @@ (* TEST -readonly_files = "main.c" -arguments = "-DINT_INT -DFUN=is_even main.c" -* asmgen + readonly_files = "main.c"; + arguments = "-DINT_INT -DFUN=is_even main.c"; + asmgen; *) (function "is_even" (b:int) diff --git a/testsuite/tests/asmgen/fib.cmm b/testsuite/tests/asmgen/fib.cmm index b5a0b5673e..6399a6c6cd 100644 --- a/testsuite/tests/asmgen/fib.cmm +++ b/testsuite/tests/asmgen/fib.cmm @@ -1,7 +1,7 @@ (* TEST -readonly_files = "main.c" -arguments = "-DINT_INT -DFUN=fib main.c" -* asmgen + readonly_files = "main.c"; + arguments = "-DINT_INT -DFUN=fib main.c"; + asmgen; *) (**************************************************************************) diff --git a/testsuite/tests/asmgen/immediates.cmm b/testsuite/tests/asmgen/immediates.cmm index f61de1ae1e..023b195408 100644 --- a/testsuite/tests/asmgen/immediates.cmm +++ b/testsuite/tests/asmgen/immediates.cmm @@ -1,7 +1,7 @@ (* TEST -readonly_files = "mainimmed.c" -arguments = "-I ${test_source_directory} mainimmed.c" -* asmgen + readonly_files = "mainimmed.c"; + arguments = "-I ${test_source_directory} mainimmed.c"; + asmgen; *) (* Regenerate with cpp -P immediates.cmmpp > immediates.cmm *) (function "testimm" () diff --git a/testsuite/tests/asmgen/integr.cmm b/testsuite/tests/asmgen/integr.cmm index 92d1cb0736..4ebee453fa 100644 --- a/testsuite/tests/asmgen/integr.cmm +++ b/testsuite/tests/asmgen/integr.cmm @@ -1,9 +1,9 @@ (* TEST -readonly_files = "main.c" -arguments = "-DINT_FLOAT -DFUN=test main.c" -* skip -reason = "This test is currently broken" -** asmgen + readonly_files = "main.c"; + arguments = "-DINT_FLOAT -DFUN=test main.c"; + reason = "This test is currently broken"; + skip; + asmgen; *) (**************************************************************************) diff --git a/testsuite/tests/asmgen/invariants.cmm b/testsuite/tests/asmgen/invariants.cmm index 6e93a46e69..8409ade0cb 100644 --- a/testsuite/tests/asmgen/invariants.cmm +++ b/testsuite/tests/asmgen/invariants.cmm @@ -1,8 +1,8 @@ (* TEST -* native-compiler -** setup-simple-build-env -*** codegen -codegen_exit_status = "2" + native-compiler; + setup-simple-build-env; + codegen_exit_status = "2"; + codegen; *) (* diff --git a/testsuite/tests/asmgen/pgcd.cmm b/testsuite/tests/asmgen/pgcd.cmm index 74e3c42395..1c669f1f3c 100644 --- a/testsuite/tests/asmgen/pgcd.cmm +++ b/testsuite/tests/asmgen/pgcd.cmm @@ -1,7 +1,7 @@ (* TEST -readonly_files = "main.c" -arguments = "-DINT_INT -DFUN=pgcd_30030 main.c" -* asmgen + readonly_files = "main.c"; + arguments = "-DINT_INT -DFUN=pgcd_30030 main.c"; + asmgen; *) (function "pgcd_30030" (a:int) diff --git a/testsuite/tests/asmgen/quicksort.cmm b/testsuite/tests/asmgen/quicksort.cmm index 58029cd16d..b5cb49fb0f 100644 --- a/testsuite/tests/asmgen/quicksort.cmm +++ b/testsuite/tests/asmgen/quicksort.cmm @@ -1,7 +1,7 @@ (* TEST -readonly_files = "main.c" -arguments = "-DSORT -DFUN=quicksort main.c" -* asmgen + readonly_files = "main.c"; + arguments = "-DSORT -DFUN=quicksort main.c"; + asmgen; *) (**************************************************************************) diff --git a/testsuite/tests/asmgen/quicksort2.cmm b/testsuite/tests/asmgen/quicksort2.cmm index 5c07a7cf5b..7f0c3cd3a0 100644 --- a/testsuite/tests/asmgen/quicksort2.cmm +++ b/testsuite/tests/asmgen/quicksort2.cmm @@ -1,7 +1,7 @@ (* TEST -readonly_files = "main.c" -arguments = "-DSORT -DFUN=quicksort main.c" -* asmgen + readonly_files = "main.c"; + arguments = "-DSORT -DFUN=quicksort main.c"; + asmgen; *) (**************************************************************************) diff --git a/testsuite/tests/asmgen/soli.cmm b/testsuite/tests/asmgen/soli.cmm index 568765116b..fccecc0a7f 100644 --- a/testsuite/tests/asmgen/soli.cmm +++ b/testsuite/tests/asmgen/soli.cmm @@ -1,7 +1,7 @@ (* TEST -readonly_files = "main.c" -arguments = "-DUNIT_INT -DFUN=solitaire main.c" -* asmgen + readonly_files = "main.c"; + arguments = "-DUNIT_INT -DFUN=solitaire main.c"; + asmgen; *) (**************************************************************************) diff --git a/testsuite/tests/asmgen/tagged-fib.cmm b/testsuite/tests/asmgen/tagged-fib.cmm index a2da4487b6..7ff1255d48 100644 --- a/testsuite/tests/asmgen/tagged-fib.cmm +++ b/testsuite/tests/asmgen/tagged-fib.cmm @@ -1,7 +1,7 @@ (* TEST -readonly_files = "main.c" -arguments = "-DINT_INT -DFUN=fib main.c" -* asmgen + readonly_files = "main.c"; + arguments = "-DINT_INT -DFUN=fib main.c"; + asmgen; *) (**************************************************************************) diff --git a/testsuite/tests/asmgen/tagged-integr.cmm b/testsuite/tests/asmgen/tagged-integr.cmm index 453e73543a..7a3cb2e98e 100644 --- a/testsuite/tests/asmgen/tagged-integr.cmm +++ b/testsuite/tests/asmgen/tagged-integr.cmm @@ -1,7 +1,7 @@ (* TEST -readonly_files = "main.c" -arguments = "-DINT_FLOAT -DFUN=test main.c" -* asmgen + readonly_files = "main.c"; + arguments = "-DINT_FLOAT -DFUN=test main.c"; + asmgen; *) (**************************************************************************) diff --git a/testsuite/tests/asmgen/tagged-quicksort.cmm b/testsuite/tests/asmgen/tagged-quicksort.cmm index 8ba8e74497..401856b963 100644 --- a/testsuite/tests/asmgen/tagged-quicksort.cmm +++ b/testsuite/tests/asmgen/tagged-quicksort.cmm @@ -1,7 +1,7 @@ (* TEST -readonly_files = "main.c" -arguments = "-DSORT -DFUN=quicksort main.c" -* asmgen + readonly_files = "main.c"; + arguments = "-DSORT -DFUN=quicksort main.c"; + asmgen; *) (**************************************************************************) diff --git a/testsuite/tests/asmgen/tagged-tak.cmm b/testsuite/tests/asmgen/tagged-tak.cmm index 8bb28a0ee0..0a79f660eb 100644 --- a/testsuite/tests/asmgen/tagged-tak.cmm +++ b/testsuite/tests/asmgen/tagged-tak.cmm @@ -1,7 +1,7 @@ (* TEST -readonly_files = "main.c" -arguments = "-DUNIT_INT -DFUN=takmain main.c" -* asmgen + readonly_files = "main.c"; + arguments = "-DUNIT_INT -DFUN=takmain main.c"; + asmgen; *) (**************************************************************************) diff --git a/testsuite/tests/asmgen/tak.cmm b/testsuite/tests/asmgen/tak.cmm index 3e8430b5c3..0d7220885e 100644 --- a/testsuite/tests/asmgen/tak.cmm +++ b/testsuite/tests/asmgen/tak.cmm @@ -1,7 +1,7 @@ (* TEST -readonly_files = "main.c" -arguments = "-DUNIT_INT -DFUN=takmain main.c" -* asmgen + readonly_files = "main.c"; + arguments = "-DUNIT_INT -DFUN=takmain main.c"; + asmgen; *) (**************************************************************************) diff --git a/testsuite/tests/ast-invariants/test.ml b/testsuite/tests/ast-invariants/test.ml index b5dbd1cbbb..47f2864412 100644 --- a/testsuite/tests/ast-invariants/test.ml +++ b/testsuite/tests/ast-invariants/test.ml @@ -1,9 +1,9 @@ (* TEST - include ocamlcommon - * hasunix - include unix - arguments = "${ocamlsrcdir}" - ** native + include ocamlcommon; + include unix; + arguments = "${ocamlsrcdir}"; + hasunix; + native; *) (* This test checks all ml files in the ocaml repository that are accepted diff --git a/testsuite/tests/backtrace/backtrace.ml b/testsuite/tests/backtrace/backtrace.ml index 5f41e8631a..598d69d0ad 100644 --- a/testsuite/tests/backtrace/backtrace.ml +++ b/testsuite/tests/backtrace/backtrace.ml @@ -21,6 +21,6 @@ let _ = ignore (g Sys.argv.(1)) (* TEST - flags = "-g" - ocamlrunparam += ",b=1" + flags = "-g"; + ocamlrunparam += ",b=1"; *) diff --git a/testsuite/tests/backtrace/backtrace2.ml b/testsuite/tests/backtrace/backtrace2.ml index 747969a48f..d4b18e446d 100644 --- a/testsuite/tests/backtrace/backtrace2.ml +++ b/testsuite/tests/backtrace/backtrace2.ml @@ -1,6 +1,6 @@ -(* TEST - flags = "-g" - ocamlrunparam += ",b=1" +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + *) (* A test for stack backtraces *) @@ -76,3 +76,8 @@ let _ = run test_lazy [| () |]; run test_lazy [| () |]; () + +(* TEST + flags = "-g"; + ocamlrunparam += ",b=1"; +*) diff --git a/testsuite/tests/backtrace/backtrace3.ml b/testsuite/tests/backtrace/backtrace3.ml index c91f0a030d..3a41f2cfa5 100644 --- a/testsuite/tests/backtrace/backtrace3.ml +++ b/testsuite/tests/backtrace/backtrace3.ml @@ -1,6 +1,6 @@ -(* TEST - flags = "-g" - ocamlrunparam += ",b=1" +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + *) (* A test for stack backtraces *) @@ -61,3 +61,8 @@ let _ = run [| "g" |]; run [| "h" |]; run [| |] + +(* TEST + flags = "-g"; + ocamlrunparam += ",b=1"; +*) diff --git a/testsuite/tests/backtrace/backtrace_bounds_exn.ml b/testsuite/tests/backtrace/backtrace_bounds_exn.ml index 5eb0975388..1c08933f96 100644 --- a/testsuite/tests/backtrace/backtrace_bounds_exn.ml +++ b/testsuite/tests/backtrace/backtrace_bounds_exn.ml @@ -1,6 +1,6 @@ -(* TEST - flags = "-g" - ocamlrunparam += ",b=1" +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + *) (* #11436: bad backtrace for out-of-bounds exception *) @@ -18,3 +18,8 @@ let _ = Printexc.print_backtrace stdout; print_endline "OK" + +(* TEST + flags = "-g"; + ocamlrunparam += ",b=1"; +*) diff --git a/testsuite/tests/backtrace/backtrace_c_exn.ml b/testsuite/tests/backtrace/backtrace_c_exn.ml index 9b0077d509..2f4ccea1b6 100644 --- a/testsuite/tests/backtrace/backtrace_c_exn.ml +++ b/testsuite/tests/backtrace/backtrace_c_exn.ml @@ -1,7 +1,7 @@ -(* TEST - modules = "backtrace_c_exn_.c" - flags = "-g" - ocamlrunparam += ",b=1" +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + *) (* https://github.com/ocaml-multicore/ocaml-multicore/issues/498 *) @@ -18,3 +18,9 @@ let () = | exn -> Printexc.to_string exn |> print_endline; Printexc.print_backtrace stdout + +(* TEST + modules = "backtrace_c_exn_.c"; + flags = "-g"; + ocamlrunparam += ",b=1"; +*) diff --git a/testsuite/tests/backtrace/backtrace_deprecated.ml b/testsuite/tests/backtrace/backtrace_deprecated.ml index 41b3c4be6b..750446a64b 100644 --- a/testsuite/tests/backtrace/backtrace_deprecated.ml +++ b/testsuite/tests/backtrace/backtrace_deprecated.ml @@ -1,6 +1,6 @@ -(* TEST - flags = "-g" - ocamlrunparam += ",b=1" +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + *) (* A test for stack backtraces *) @@ -40,3 +40,8 @@ let _ = run [| "c" |]; run [| "d" |]; run [| |] + +(* TEST + flags = "-g"; + ocamlrunparam += ",b=1"; +*) diff --git a/testsuite/tests/backtrace/backtrace_dynlink.ml b/testsuite/tests/backtrace/backtrace_dynlink.ml index 3252f53f67..7caf291801 100644 --- a/testsuite/tests/backtrace/backtrace_dynlink.ml +++ b/testsuite/tests/backtrace/backtrace_dynlink.ml @@ -1,32 +1,32 @@ -(* TEST +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + + + + + + + + + + + + + + + + + + + + + + + -include dynlink - -readonly_files = "backtrace_dynlink_plugin.ml" - -libraries = "" - -* shared-libraries -** native-dynlink -*** setup-ocamlopt.byte-build-env -**** ocamlopt.byte -module = "backtrace_dynlink.ml" -flags = "-g" -**** ocamlopt.byte -program = "backtrace_dynlink_plugin.cmxs" -flags = "-shared -g" -all_modules = "backtrace_dynlink_plugin.ml" -**** ocamlopt.byte -program = "${test_build_directory}/main.exe" -libraries = "dynlink" -all_modules = "backtrace_dynlink.cmx" -***** run -ocamlrunparam += ",b=1" -****** no-flambda -******* check-program-output -****** flambda -reference = "${test_source_directory}/backtrace_dynlink.flambda.reference" -******* check-program-output *) (* test for backtrace and stack unwinding with dynlink. *) @@ -44,3 +44,37 @@ let () = | exn -> Printexc.to_string exn |> print_endline; print_endline "ERROR" + +(* TEST + include dynlink; + readonly_files = "backtrace_dynlink_plugin.ml"; + libraries = ""; + shared-libraries; + native-dynlink; + setup-ocamlopt.byte-build-env; + { + module = "backtrace_dynlink.ml"; + flags = "-g"; + ocamlopt.byte; + }{ + program = "backtrace_dynlink_plugin.cmxs"; + flags = "-shared -g"; + all_modules = "backtrace_dynlink_plugin.ml"; + ocamlopt.byte; + }{ + program = "${test_build_directory}/main.exe"; + libraries = "dynlink"; + all_modules = "backtrace_dynlink.cmx"; + ocamlopt.byte; + ocamlrunparam += ",b=1"; + run; + { + no-flambda; + check-program-output; + }{ + reference = "${test_source_directory}/backtrace_dynlink.flambda.reference"; + flambda; + check-program-output; + } + } +*) diff --git a/testsuite/tests/backtrace/backtrace_effects.ml b/testsuite/tests/backtrace/backtrace_effects.ml index 352b32cbd7..762e27549e 100644 --- a/testsuite/tests/backtrace/backtrace_effects.ml +++ b/testsuite/tests/backtrace/backtrace_effects.ml @@ -1,7 +1,7 @@ -(* TEST - flags = "-g" - ocamlrunparam += ",b=1" - exit_status = "2" +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + *) open Effect @@ -39,3 +39,9 @@ let baz () = | _ -> None } let _ = baz () + +(* TEST + flags = "-g"; + ocamlrunparam += ",b=1"; + exit_status = "2"; +*) diff --git a/testsuite/tests/backtrace/backtrace_effects_nested.ml b/testsuite/tests/backtrace/backtrace_effects_nested.ml index 37638a200a..e9da62ab51 100644 --- a/testsuite/tests/backtrace/backtrace_effects_nested.ml +++ b/testsuite/tests/backtrace/backtrace_effects_nested.ml @@ -1,12 +1,12 @@ -(* TEST +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + + + -flags = "-g" -* bytecode -* no-flambda -** native -* flambda -reference = "${test_source_directory}/backtrace_effects_nested.flambda.reference" -** native *) @@ -43,3 +43,17 @@ let f () = | _ -> None } let () = f () + +(* TEST + flags = "-g"; + { + bytecode; + }{ + no-flambda; + native; + }{ + reference = "${test_source_directory}/backtrace_effects_nested.flambda.reference"; + flambda; + native; + } +*) diff --git a/testsuite/tests/backtrace/backtrace_or_exception.ml b/testsuite/tests/backtrace/backtrace_or_exception.ml index dc8f53c077..6f9fc0af44 100644 --- a/testsuite/tests/backtrace/backtrace_or_exception.ml +++ b/testsuite/tests/backtrace/backtrace_or_exception.ml @@ -1,6 +1,6 @@ -(* TEST - flags = "-g" - ocamlrunparam += ",b=1" +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + *) exception Exn @@ -46,3 +46,8 @@ let _ = run without_reraise; run with_reraise; run trickier + +(* TEST + flags = "-g"; + ocamlrunparam += ",b=1"; +*) diff --git a/testsuite/tests/backtrace/backtrace_slots.ml b/testsuite/tests/backtrace/backtrace_slots.ml index d6b95a0d4e..22e3e9a13c 100644 --- a/testsuite/tests/backtrace/backtrace_slots.ml +++ b/testsuite/tests/backtrace/backtrace_slots.ml @@ -1,6 +1,6 @@ -(* TEST - flags = "-g" - ocamlrunparam += ",b=1" +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + *) (* A test for stack backtraces *) @@ -62,3 +62,8 @@ let _ = run [| "c" |]; run [| "d" |]; run [| |] + +(* TEST + flags = "-g"; + ocamlrunparam += ",b=1"; +*) diff --git a/testsuite/tests/backtrace/backtrace_systhreads.ml b/testsuite/tests/backtrace/backtrace_systhreads.ml index 1b6b158cef..e6e7bd97c4 100644 --- a/testsuite/tests/backtrace/backtrace_systhreads.ml +++ b/testsuite/tests/backtrace/backtrace_systhreads.ml @@ -1,10 +1,10 @@ -(* TEST -flags = "-g" -ocamlrunparam += ",b=1" -* hassysthreads -include systhreads -** bytecode -** native +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + + *) let throw_exn msg = failwith msg [@@inline never] @@ -38,3 +38,15 @@ let () = List.iter Thread.join threads; Condition.signal cond; Thread.join backtrace_thread + +(* TEST + flags = "-g"; + ocamlrunparam += ",b=1"; + include systhreads; + hassysthreads; + { + bytecode; + }{ + native; + } +*) diff --git a/testsuite/tests/backtrace/backtraces_and_finalizers.ml b/testsuite/tests/backtrace/backtraces_and_finalizers.ml index 60c02f48ea..a204b9affc 100644 --- a/testsuite/tests/backtrace/backtraces_and_finalizers.ml +++ b/testsuite/tests/backtrace/backtraces_and_finalizers.ml @@ -1,7 +1,7 @@ (* TEST - flags = "-g -inline 0" - ocamlrunparam += ",b=1" - * native + flags = "-g -inline 0"; + ocamlrunparam += ",b=1"; + native; *) let finaliser _ = try raise Exit with _ -> () diff --git a/testsuite/tests/backtrace/callstack.ml b/testsuite/tests/backtrace/callstack.ml index 5c33816e06..4c115351e1 100644 --- a/testsuite/tests/backtrace/callstack.ml +++ b/testsuite/tests/backtrace/callstack.ml @@ -1,10 +1,10 @@ -(* TEST - flags = "-g" - * hassysthreads - include systhreads - ** no-flambda - *** native - *** bytecode +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + + *) let[@inline never] f0 () = @@ -29,3 +29,15 @@ let () = the callstack, which breaks the test. *) let () = Printf.printf "new thread:\n" let () = Thread.join (Thread.create f3 ()) + +(* TEST + flags = "-g"; + include systhreads; + hassysthreads; + no-flambda; + { + native; + }{ + bytecode; + } +*) diff --git a/testsuite/tests/backtrace/event_after_prim.ml b/testsuite/tests/backtrace/event_after_prim.ml index 6af09a5fa4..f8f54c4f40 100644 --- a/testsuite/tests/backtrace/event_after_prim.ml +++ b/testsuite/tests/backtrace/event_after_prim.ml @@ -1,5 +1,5 @@ -(* TEST - flags = "-g" +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) *) let f n b = @@ -12,3 +12,7 @@ let () = | _ -> assert false | exception _ -> Printexc.print_backtrace stdout + +(* TEST + flags = "-g"; +*) diff --git a/testsuite/tests/backtrace/inline_test.ml b/testsuite/tests/backtrace/inline_test.ml index f8ffe38f7e..1c3b024d5a 100644 --- a/testsuite/tests/backtrace/inline_test.ml +++ b/testsuite/tests/backtrace/inline_test.ml @@ -1,11 +1,11 @@ -(* TEST - flags = "-g" - ocamlrunparam += ",b=1" - * bytecode - * native - * native - ocamlopt_flags = "-O3" - compiler_directory_suffix = ".O3" +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + + + *) (* A test for inlined stack backtraces *) @@ -24,3 +24,17 @@ let i x = let () = i () + +(* TEST + flags = "-g"; + ocamlrunparam += ",b=1"; + { + bytecode; + }{ + native; + }{ + ocamlopt_flags = "-O3"; + compiler_directory_suffix = ".O3"; + native; + } +*) diff --git a/testsuite/tests/backtrace/inline_traversal_test.ml b/testsuite/tests/backtrace/inline_traversal_test.ml index d70c7fc52e..8fa5803b88 100644 --- a/testsuite/tests/backtrace/inline_traversal_test.ml +++ b/testsuite/tests/backtrace/inline_traversal_test.ml @@ -1,11 +1,11 @@ -(* TEST - flags = "-g" - ocamlrunparam += ",b=1" - * bytecode - * native - * native - ocamlopt_flags = "-O3" - compiler_directory_suffix = ".O3" +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + + + *) (* A test for inlined stack backtraces *) @@ -52,3 +52,17 @@ let () = Printf.printf "Frame %d\n" i; print_slots (Some slot) done + +(* TEST + flags = "-g"; + ocamlrunparam += ",b=1"; + { + bytecode; + }{ + native; + }{ + ocamlopt_flags = "-O3"; + compiler_directory_suffix = ".O3"; + native; + } +*) diff --git a/testsuite/tests/backtrace/lazy.ml b/testsuite/tests/backtrace/lazy.ml index c6a0626b42..362539a9f7 100644 --- a/testsuite/tests/backtrace/lazy.ml +++ b/testsuite/tests/backtrace/lazy.ml @@ -24,12 +24,13 @@ let () = (* TEST - -flags = "-g" -* no-flambda -** native -* flambda -reference = "${test_source_directory}/lazy.flambda.reference" -** native - + flags = "-g"; + { + no-flambda; + native; + }{ + reference = "${test_source_directory}/lazy.flambda.reference"; + flambda; + native; + } *) diff --git a/testsuite/tests/backtrace/methods.ml b/testsuite/tests/backtrace/methods.ml index f016fb51c9..7a449c4a27 100644 --- a/testsuite/tests/backtrace/methods.ml +++ b/testsuite/tests/backtrace/methods.ml @@ -1,5 +1,5 @@ -(* TEST - flags = "-g" +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) *) let[@inline never] id x = Sys.opaque_identity x @@ -26,3 +26,7 @@ let () = | _ -> assert false | exception Exit -> Printexc.print_backtrace stdout + +(* TEST + flags = "-g"; +*) diff --git a/testsuite/tests/backtrace/names.ml b/testsuite/tests/backtrace/names.ml index 06fc9ddffd..89952926b3 100644 --- a/testsuite/tests/backtrace/names.ml +++ b/testsuite/tests/backtrace/names.ml @@ -1,6 +1,6 @@ -(* TEST - flags = "-g" - *) +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) +*) let id x = Sys.opaque_identity x @@ -121,3 +121,7 @@ let () = | _ -> assert false | exception Exit -> Printexc.print_backtrace stdout + +(* TEST + flags = "-g"; +*) diff --git a/testsuite/tests/backtrace/pr2195.ml b/testsuite/tests/backtrace/pr2195.ml index e0442a3405..e45ea55d90 100644 --- a/testsuite/tests/backtrace/pr2195.ml +++ b/testsuite/tests/backtrace/pr2195.ml @@ -1,18 +1,18 @@ -(* TEST - flags += "-g" - exit_status = "2" - * bytecode - ocamlrunparam += ",b=0" - reference = "${test_source_directory}/pr2195-nolocs.byte.reference" - * bytecode - ocamlrunparam += ",b=1" - reference = "${test_source_directory}/pr2195-nolocs.byte.reference" - * bytecode - ocamlrunparam += ",b=2" - reference = "${test_source_directory}/pr2195-locs.byte.reference" - * native - reference = "${test_source_directory}/pr2195.opt.reference" - compare_programs = "false" +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + + + + + + + + + + *) let () = @@ -27,3 +27,25 @@ let () = (* The message is platform-specific, so convert the exception to Exit *) let bt = Printexc.get_raw_backtrace () in Printexc.raise_with_backtrace Exit bt + +(* TEST + flags += "-g"; + exit_status = "2"; + { + ocamlrunparam += ",b=0"; + reference = "${test_source_directory}/pr2195-nolocs.byte.reference"; + bytecode; + }{ + ocamlrunparam += ",b=1"; + reference = "${test_source_directory}/pr2195-nolocs.byte.reference"; + bytecode; + }{ + ocamlrunparam += ",b=2"; + reference = "${test_source_directory}/pr2195-locs.byte.reference"; + bytecode; + }{ + reference = "${test_source_directory}/pr2195.opt.reference"; + compare_programs = "false"; + native; + } +*) diff --git a/testsuite/tests/backtrace/pr6920_why_at.ml b/testsuite/tests/backtrace/pr6920_why_at.ml index 1a0583a62f..9101066b11 100644 --- a/testsuite/tests/backtrace/pr6920_why_at.ml +++ b/testsuite/tests/backtrace/pr6920_why_at.ml @@ -1,8 +1,8 @@ -(* TEST - flags = "-g" - ocamlrunparam += ",b=1" - ocamlopt_flags = "-inline 0" - exit_status = "2" +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + *) let why : unit -> unit = fun () -> raise Exit [@@inline never] @@ -13,3 +13,10 @@ let f () = let () = f () + +(* TEST + flags = "-g"; + ocamlrunparam += ",b=1"; + ocamlopt_flags = "-inline 0"; + exit_status = "2"; +*) diff --git a/testsuite/tests/backtrace/pr6920_why_swallow.ml b/testsuite/tests/backtrace/pr6920_why_swallow.ml index b1e5d60f16..05c8188583 100644 --- a/testsuite/tests/backtrace/pr6920_why_swallow.ml +++ b/testsuite/tests/backtrace/pr6920_why_swallow.ml @@ -1,8 +1,8 @@ -(* TEST - flags = "-g" - ocamlrunparam += ",b=1" - ocamlopt_flags = "-inline 0" - exit_status = "2" +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + *) let why : unit -> unit = fun () -> raise Exit [@@inline never] @@ -15,3 +15,10 @@ let f () = let () = f () + +(* TEST + flags = "-g"; + ocamlrunparam += ",b=1"; + ocamlopt_flags = "-inline 0"; + exit_status = "2"; +*) diff --git a/testsuite/tests/backtrace/raw_backtrace.ml b/testsuite/tests/backtrace/raw_backtrace.ml index a685133a7b..44d9ce5b3a 100644 --- a/testsuite/tests/backtrace/raw_backtrace.ml +++ b/testsuite/tests/backtrace/raw_backtrace.ml @@ -1,6 +1,6 @@ -(* TEST - flags = "-g" - ocamlrunparam += ",b=1" +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + *) (* A test for stack backtraces *) @@ -60,3 +60,8 @@ let _ = run [| "e" |]; run [| "f" |]; run [| |] + +(* TEST + flags = "-g"; + ocamlrunparam += ",b=1"; +*) diff --git a/testsuite/tests/badly-ordered-deps/main.ml b/testsuite/tests/badly-ordered-deps/main.ml index ff4d1c90a1..ba6c6cfb97 100644 --- a/testsuite/tests/badly-ordered-deps/main.ml +++ b/testsuite/tests/badly-ordered-deps/main.ml @@ -1,26 +1,19 @@ (* TEST + modules = "lib.ml"; + setup-ocamlc.byte-build-env; + all_modules = "main.ml"; + compile_only = "true"; + ocamlc.byte; + all_modules = "lib.ml"; + ocamlc.byte; + all_modules = "lib.cmo main.cmo"; + compile_only = "false"; + ocamlc_byte_exit_status = "2"; + ocamlc.byte; + check-ocamlc.byte-output; +*) -(* Make sure ocamlc prints badly ordeered dependencies only once. +(* Make sure ocamlc prints badly ordered dependencies only once. See issue #12074. We test with ocamlc.byte only. *) -modules = "lib.ml" - -* setup-ocamlc.byte-build-env - -** ocamlc.byte -all_modules = "main.ml" -compile_only = "true" - -*** ocamlc.byte -all_modules = "lib.ml" - -**** ocamlc.byte -all_modules = "lib.cmo main.cmo" -compile_only = "false" -ocamlc_byte_exit_status = "2" - -***** check-ocamlc.byte-output - -*) - let value = () diff --git a/testsuite/tests/basic-io-2/io.ml b/testsuite/tests/basic-io-2/io.ml index 016ac1549b..75117f0e95 100644 --- a/testsuite/tests/basic-io-2/io.ml +++ b/testsuite/tests/basic-io-2/io.ml @@ -1,6 +1,6 @@ (* TEST - arguments = "io.ml" - readonly_files = "test-file-short-lines" + arguments = "io.ml"; + readonly_files = "test-file-short-lines"; *) (* Test a file copy function *) diff --git a/testsuite/tests/basic-io/wc.ml b/testsuite/tests/basic-io/wc.ml index 33e7911597..9e88d54c40 100644 --- a/testsuite/tests/basic-io/wc.ml +++ b/testsuite/tests/basic-io/wc.ml @@ -1,5 +1,5 @@ (* TEST - arguments = "wc.ml" + arguments = "wc.ml"; *) (* Counts characters, lines and words in one or several files. *) diff --git a/testsuite/tests/basic-manyargs/manyargs.ml b/testsuite/tests/basic-manyargs/manyargs.ml index 53d3a59592..21f5776d80 100644 --- a/testsuite/tests/basic-manyargs/manyargs.ml +++ b/testsuite/tests/basic-manyargs/manyargs.ml @@ -1,5 +1,5 @@ (* TEST - modules = "manyargsprim.c" + modules = "manyargsprim.c"; *) let manyargs a b c d e f g h i j k l m n o = diff --git a/testsuite/tests/basic-modules/anonymous.ml b/testsuite/tests/basic-modules/anonymous.ml index 20e67cca17..5c6affca9e 100644 --- a/testsuite/tests/basic-modules/anonymous.ml +++ b/testsuite/tests/basic-modules/anonymous.ml @@ -1,19 +1,19 @@ -(* TEST -flags = "-c -nostdlib -nopervasives -dlambda -dno-unique-ids" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output -compiler_reference = "${test_source_directory}/anonymous.ocamlc.reference" - -* setup-ocamlopt.byte-build-env -** ocamlopt.byte -*** no-flambda -**** check-ocamlopt.byte-output -compiler_reference = "${test_source_directory}/anonymous.ocamlopt.reference" -*** flambda -**** check-ocamlc.byte-output -compiler_reference = - "${test_source_directory}/anonymous.ocamlopt.flambda.reference" +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + + + + + + + + + + + *) module _ = struct @@ -53,3 +53,25 @@ end let drop _ = () let () = drop s.cell + +(* TEST + flags = "-c -nostdlib -nopervasives -dlambda -dno-unique-ids"; + { + setup-ocamlc.byte-build-env; + ocamlc.byte; + compiler_reference = "${test_source_directory}/anonymous.ocamlc.reference"; + check-ocamlc.byte-output; + }{ + setup-ocamlopt.byte-build-env; + ocamlopt.byte; + { + no-flambda; + compiler_reference = "${test_source_directory}/anonymous.ocamlopt.reference"; + check-ocamlopt.byte-output; + }{ + flambda; + compiler_reference = "${test_source_directory}/anonymous.ocamlopt.flambda.reference"; + check-ocamlc.byte-output; + } + } +*) diff --git a/testsuite/tests/basic-modules/main.ml b/testsuite/tests/basic-modules/main.ml index bd6d4ff344..8abcf6c3a8 100644 --- a/testsuite/tests/basic-modules/main.ml +++ b/testsuite/tests/basic-modules/main.ml @@ -1,5 +1,5 @@ (* TEST - modules = "offset.ml pr6726.ml pr7427.ml pr4008.ml" + modules = "offset.ml pr6726.ml pr7427.ml pr4008.ml"; *) (* PR#6435 *) diff --git a/testsuite/tests/basic-modules/recursive_module_evaluation_errors.ml b/testsuite/tests/basic-modules/recursive_module_evaluation_errors.ml index b0fdd12c31..0db608aef6 100644 --- a/testsuite/tests/basic-modules/recursive_module_evaluation_errors.ml +++ b/testsuite/tests/basic-modules/recursive_module_evaluation_errors.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module rec A: sig val x: int end = struct let x = B.x end diff --git a/testsuite/tests/basic-more/bounds.ml b/testsuite/tests/basic-more/bounds.ml index 9915853f6c..2ffd972e30 100644 --- a/testsuite/tests/basic-more/bounds.ml +++ b/testsuite/tests/basic-more/bounds.ml @@ -1,5 +1,5 @@ (* TEST - include testing + include testing; *) (* Test bound checks *) diff --git a/testsuite/tests/basic-more/div_by_zero.ml b/testsuite/tests/basic-more/div_by_zero.ml index 7cd910768e..5c033e24d7 100644 --- a/testsuite/tests/basic-more/div_by_zero.ml +++ b/testsuite/tests/basic-more/div_by_zero.ml @@ -1,5 +1,5 @@ (* TEST - include testing + include testing; *) let check f n = diff --git a/testsuite/tests/basic-more/function_in_ref.ml b/testsuite/tests/basic-more/function_in_ref.ml index 481384095d..fd4446cbba 100644 --- a/testsuite/tests/basic-more/function_in_ref.ml +++ b/testsuite/tests/basic-more/function_in_ref.ml @@ -1,5 +1,5 @@ (* TEST - include testing + include testing; *) let f x = x + 1 diff --git a/testsuite/tests/basic-more/if_in_if.ml b/testsuite/tests/basic-more/if_in_if.ml index cf3525d2fe..ad51f970c3 100644 --- a/testsuite/tests/basic-more/if_in_if.ml +++ b/testsuite/tests/basic-more/if_in_if.ml @@ -1,5 +1,5 @@ (* TEST - include testing + include testing; *) let sequor b1 b2 = diff --git a/testsuite/tests/basic-more/morematch.ml b/testsuite/tests/basic-more/morematch.ml index 998daee62c..130c1edad6 100644 --- a/testsuite/tests/basic-more/morematch.ml +++ b/testsuite/tests/basic-more/morematch.ml @@ -1,5 +1,5 @@ -(* TEST - include testing +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) *) (**************************************************************) @@ -1157,3 +1157,7 @@ let pr5758 x str = let () = test "pr5758" (pr5758 1.) "A" "Matched A" ;; + +(* TEST + include testing; +*) diff --git a/testsuite/tests/basic-more/opaque_prim.ml b/testsuite/tests/basic-more/opaque_prim.ml index bdb60250ee..3456f5339e 100644 --- a/testsuite/tests/basic-more/opaque_prim.ml +++ b/testsuite/tests/basic-more/opaque_prim.ml @@ -1,5 +1,5 @@ (* TEST - include testing + include testing; *) let f x = Sys.opaque_identity x diff --git a/testsuite/tests/basic-more/pr10338.ml b/testsuite/tests/basic-more/pr10338.ml index 7697f377f8..2f63667b2a 100644 --- a/testsuite/tests/basic-more/pr10338.ml +++ b/testsuite/tests/basic-more/pr10338.ml @@ -1,4 +1,4 @@ -(* TEST *) +(* TEST_BELOW*) (* exercise push_defaults *) @@ -24,3 +24,6 @@ print_endline (f (module struct exception Ex end) Exit);; let f ?(x = assert false) ((module M) : (module E)) () = 1;; (* so partial application of the module doesn't raise *) let partial = f (module struct exception Ex end);; + +(* TEST +*) diff --git a/testsuite/tests/basic-more/pr1271.ml b/testsuite/tests/basic-more/pr1271.ml index adbb8734ff..9c67dd9c34 100644 --- a/testsuite/tests/basic-more/pr1271.ml +++ b/testsuite/tests/basic-more/pr1271.ml @@ -1,5 +1,5 @@ (* TEST - include testing + include testing; *) (* GPR#1271 *) diff --git a/testsuite/tests/basic-more/pr2719.ml b/testsuite/tests/basic-more/pr2719.ml index cb69aeae34..7bddbf9345 100644 --- a/testsuite/tests/basic-more/pr2719.ml +++ b/testsuite/tests/basic-more/pr2719.ml @@ -1,5 +1,5 @@ (* TEST - include testing + include testing; *) open Printf diff --git a/testsuite/tests/basic-more/pr6216.ml b/testsuite/tests/basic-more/pr6216.ml index 3f6b410993..89dba12f28 100644 --- a/testsuite/tests/basic-more/pr6216.ml +++ b/testsuite/tests/basic-more/pr6216.ml @@ -1,6 +1,6 @@ (* TEST - include testing - ocamlopt_flags ="-inline 20" + include testing; + ocamlopt_flags = "-inline 20"; *) (* PR6216: wrong inlining of GADT match *) diff --git a/testsuite/tests/basic-more/record_evaluation_order.ml b/testsuite/tests/basic-more/record_evaluation_order.ml index f8d1d568b3..66780ea237 100644 --- a/testsuite/tests/basic-more/record_evaluation_order.ml +++ b/testsuite/tests/basic-more/record_evaluation_order.ml @@ -1,5 +1,5 @@ (* TEST - include testing + include testing; *) type r = diff --git a/testsuite/tests/basic-more/robustmatch.ml b/testsuite/tests/basic-more/robustmatch.ml index e4768d0a66..5aea6d1f53 100644 --- a/testsuite/tests/basic-more/robustmatch.ml +++ b/testsuite/tests/basic-more/robustmatch.ml @@ -1,6 +1,6 @@ (* TEST - flags += "-w +4+8+9+11+12+52+56+57" - include testing + flags += "-w +4+8+9+11+12+52+56+57"; + include testing; *) module GPR1493 = struct diff --git a/testsuite/tests/basic-more/safer_matching.ml b/testsuite/tests/basic-more/safer_matching.ml index 0720b4c3fc..668c521968 100644 --- a/testsuite/tests/basic-more/safer_matching.ml +++ b/testsuite/tests/basic-more/safer_matching.ml @@ -1,5 +1,5 @@ -(* TEST - flags += "-safer-matching" +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) *) type 'a dyn = Int : int -> int dyn | Float : float -> float dyn;; @@ -9,3 +9,7 @@ let f (Float x) = x;; Format.printf "%f\n%!" (f (Float 3.1415));; try Printexc.print f (Obj.magic (Int 3)) with _ -> 0.;; + +(* TEST + flags += "-safer-matching"; +*) diff --git a/testsuite/tests/basic-more/sequential_and_or.ml b/testsuite/tests/basic-more/sequential_and_or.ml index 926cb9ab58..16c1367a41 100644 --- a/testsuite/tests/basic-more/sequential_and_or.ml +++ b/testsuite/tests/basic-more/sequential_and_or.ml @@ -1,5 +1,5 @@ (* TEST - include testing + include testing; *) let r = ref 0 diff --git a/testsuite/tests/basic-more/structural_constants.ml b/testsuite/tests/basic-more/structural_constants.ml index 66cff92b3f..55a4287c55 100644 --- a/testsuite/tests/basic-more/structural_constants.ml +++ b/testsuite/tests/basic-more/structural_constants.ml @@ -1,5 +1,5 @@ (* TEST - include testing + include testing; *) type t1 = diff --git a/testsuite/tests/basic-more/tbuffer.ml b/testsuite/tests/basic-more/tbuffer.ml index c3f96b7345..7daff1b576 100644 --- a/testsuite/tests/basic-more/tbuffer.ml +++ b/testsuite/tests/basic-more/tbuffer.ml @@ -1,5 +1,5 @@ (* TEST - include testing + include testing; *) (* Dummy substitute function. *) diff --git a/testsuite/tests/basic-more/top_level_patterns.ml b/testsuite/tests/basic-more/top_level_patterns.ml index aca641fc4f..a253bfe5a0 100644 --- a/testsuite/tests/basic-more/top_level_patterns.ml +++ b/testsuite/tests/basic-more/top_level_patterns.ml @@ -1,5 +1,5 @@ (* TEST - include testing + include testing; *) type t = diff --git a/testsuite/tests/basic-more/tprintf.ml b/testsuite/tests/basic-more/tprintf.ml index e1cb4c0a7b..d4bde0bbae 100644 --- a/testsuite/tests/basic-more/tprintf.ml +++ b/testsuite/tests/basic-more/tprintf.ml @@ -1,5 +1,5 @@ (* TEST - include testing + include testing; *) open Testing;; diff --git a/testsuite/tests/basic-multdef/usemultdef.ml b/testsuite/tests/basic-multdef/usemultdef.ml index 477cf4ced5..858b478d0c 100644 --- a/testsuite/tests/basic-multdef/usemultdef.ml +++ b/testsuite/tests/basic-multdef/usemultdef.ml @@ -1,5 +1,5 @@ (* TEST - modules = "multdef.ml" + modules = "multdef.ml"; *) let _ = print_int(Multdef.f 1); print_newline(); exit 0 diff --git a/testsuite/tests/basic-private/tlength.ml b/testsuite/tests/basic-private/tlength.ml index 00ce4cc843..7a43ddff1c 100644 --- a/testsuite/tests/basic-private/tlength.ml +++ b/testsuite/tests/basic-private/tlength.ml @@ -1,5 +1,5 @@ (* TEST - modules = "length.ml" + modules = "length.ml"; *) (* diff --git a/testsuite/tests/basic/constprop.ml.c b/testsuite/tests/basic/constprop.ml.c index ee23d48992..805aa9d600 100644 --- a/testsuite/tests/basic/constprop.ml.c +++ b/testsuite/tests/basic/constprop.ml.c @@ -1,9 +1,12 @@ (* TEST - flags = "-pp '${c_preprocessor}'" - ocaml_filetype_flag = "-impl" - * bytecode - compare_programs = "false" - * native + flags = "-pp '${c_preprocessor}'"; + ocaml_filetype_flag = "-impl"; + { + compare_programs = "false"; + bytecode; + }{ + native; + } *) (* This file has extension .ml.c because it needs to be preprocessed diff --git a/testsuite/tests/basic/opt_variants.ml b/testsuite/tests/basic/opt_variants.ml index 7083a03d7a..c36c1b112a 100644 --- a/testsuite/tests/basic/opt_variants.ml +++ b/testsuite/tests/basic/opt_variants.ml @@ -1,5 +1,5 @@ (* TEST -unset DOES_NOT_EXIST + unset DOES_NOT_EXIST; *) let () = diff --git a/testsuite/tests/basic/patmatch_for_multiple.ml b/testsuite/tests/basic/patmatch_for_multiple.ml index 0f532c5b5f..d3f3f1409e 100644 --- a/testsuite/tests/basic/patmatch_for_multiple.ml +++ b/testsuite/tests/basic/patmatch_for_multiple.ml @@ -1,6 +1,6 @@ (* TEST - flags = "-drawlambda -dlambda" - * expect + flags = "-drawlambda -dlambda"; + expect; *) (* Note: the tests below contain *both* the -drawlambda and diff --git a/testsuite/tests/basic/patmatch_incoherence.ml b/testsuite/tests/basic/patmatch_incoherence.ml index b4b951ca51..ecf6b0b813 100644 --- a/testsuite/tests/basic/patmatch_incoherence.ml +++ b/testsuite/tests/basic/patmatch_incoherence.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type tlist = { x: 'a. 'a list };; diff --git a/testsuite/tests/basic/patmatch_split_no_or.ml b/testsuite/tests/basic/patmatch_split_no_or.ml index 57427d9524..2ceb5c4036 100644 --- a/testsuite/tests/basic/patmatch_split_no_or.ml +++ b/testsuite/tests/basic/patmatch_split_no_or.ml @@ -1,7 +1,7 @@ (* TEST - flags = "-nostdlib -nopervasives -dlambda" - * expect - *) + flags = "-nostdlib -nopervasives -dlambda"; + expect; +*) (******************************************************************************) diff --git a/testsuite/tests/basic/unit_naming.ml b/testsuite/tests/basic/unit_naming.ml index 6b7a65c255..8bbe391b25 100644 --- a/testsuite/tests/basic/unit_naming.ml +++ b/testsuite/tests/basic/unit_naming.ml @@ -1,9 +1,17 @@ -(* TEST - modules = "camlCase.ml" - * setup-ocamlc.byte-build-env - ** ocamlc.byte - ocamlc_byte_exit_status = "2" - *** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) print_int Camlcase.answer + +(* TEST + modules = "camlCase.ml"; + setup-ocamlc.byte-build-env; + ocamlc_byte_exit_status = "2"; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/c-api/alloc_async.ml b/testsuite/tests/c-api/alloc_async.ml index b8c99a4b07..abbf729bd6 100644 --- a/testsuite/tests/c-api/alloc_async.ml +++ b/testsuite/tests/c-api/alloc_async.ml @@ -1,7 +1,7 @@ (* TEST - modules = "alloc_async_stubs.c" - * skip - reason = "alloc async changes: https://github.com/ocaml/ocaml/pull/8897" + modules = "alloc_async_stubs.c"; + reason = "alloc async changes: https://github.com/ocaml/ocaml/pull/8897"; + skip; *) external test : int ref -> unit = "stub" diff --git a/testsuite/tests/c-api/test_c_thread_has_lock.ml b/testsuite/tests/c-api/test_c_thread_has_lock.ml index e826001559..a7b176c8d1 100644 --- a/testsuite/tests/c-api/test_c_thread_has_lock.ml +++ b/testsuite/tests/c-api/test_c_thread_has_lock.ml @@ -1,7 +1,10 @@ (* TEST - modules = "test_c_thread_has_lock_cstubs.c" - * bytecode - * native + modules = "test_c_thread_has_lock_cstubs.c"; + { + bytecode; + }{ + native; + } *) external test_with_lock : unit -> bool = "with_lock" diff --git a/testsuite/tests/c-api/test_c_thread_has_lock_systhread.ml b/testsuite/tests/c-api/test_c_thread_has_lock_systhread.ml index 65327be652..ac043c5e92 100644 --- a/testsuite/tests/c-api/test_c_thread_has_lock_systhread.ml +++ b/testsuite/tests/c-api/test_c_thread_has_lock_systhread.ml @@ -1,9 +1,12 @@ (* TEST - modules = "test_c_thread_has_lock_cstubs.c" - * hassysthreads - include systhreads - ** bytecode - ** native + modules = "test_c_thread_has_lock_cstubs.c"; + include systhreads; + hassysthreads; + { + bytecode; + }{ + native; + } *) external test_with_lock : unit -> bool = "with_lock" diff --git a/testsuite/tests/callback/callback_effects_gc.ml b/testsuite/tests/callback/callback_effects_gc.ml index 191a23e0ff..50b5ac02f9 100644 --- a/testsuite/tests/callback/callback_effects_gc.ml +++ b/testsuite/tests/callback/callback_effects_gc.ml @@ -1,6 +1,6 @@ (* TEST - ocamlrunparam += ",s=512" - * native + ocamlrunparam += ",s=512"; + native; *) let count = ref 0 diff --git a/testsuite/tests/callback/minor_named.ml b/testsuite/tests/callback/minor_named.ml index 9bc01b77d5..77b5e03118 100644 --- a/testsuite/tests/callback/minor_named.ml +++ b/testsuite/tests/callback/minor_named.ml @@ -1,9 +1,12 @@ (* TEST - include unix - modules = "minor_named_.c" - * libunix - ** bytecode - ** native + include unix; + modules = "minor_named_.c"; + libunix; + { + bytecode; + }{ + native; + } *) (* Tests Callback.register and caml_named_value on a young object *) diff --git a/testsuite/tests/callback/nested_fiber.ml b/testsuite/tests/callback/nested_fiber.ml index 3786e455ef..2d144c09e7 100644 --- a/testsuite/tests/callback/nested_fiber.ml +++ b/testsuite/tests/callback/nested_fiber.ml @@ -1,9 +1,12 @@ (* TEST - include unix - modules = "nested_fiber_.c" - * libunix - ** bytecode - ** native + include unix; + modules = "nested_fiber_.c"; + libunix; + { + bytecode; + }{ + native; + } *) external caml_to_c : (unit -> 'a) -> 'a = "caml_to_c" diff --git a/testsuite/tests/callback/signals_alloc.ml b/testsuite/tests/callback/signals_alloc.ml index 27ed2f7da6..ba3c9fbe3f 100644 --- a/testsuite/tests/callback/signals_alloc.ml +++ b/testsuite/tests/callback/signals_alloc.ml @@ -1,9 +1,12 @@ (* TEST - include unix - modules = "callbackprim.c" - * libunix - ** bytecode - ** native + include unix; + modules = "callbackprim.c"; + libunix; + { + bytecode; + }{ + native; + } *) external raise_sigusr1 : unit -> unit = "raise_sigusr1" diff --git a/testsuite/tests/callback/stack_overflow.ml b/testsuite/tests/callback/stack_overflow.ml index 23691dcf6c..9b48df20e9 100644 --- a/testsuite/tests/callback/stack_overflow.ml +++ b/testsuite/tests/callback/stack_overflow.ml @@ -1,9 +1,12 @@ (* TEST - include unix - modules = "stack_overflow_.c" - * libunix - ** bytecode - ** native + include unix; + modules = "stack_overflow_.c"; + libunix; + { + bytecode; + }{ + native; + } *) external caml_to_c : (unit -> 'a) -> 'a = "caml_to_c" diff --git a/testsuite/tests/callback/test1.ml b/testsuite/tests/callback/test1.ml index 7c45945a8b..e481d52aa9 100644 --- a/testsuite/tests/callback/test1.ml +++ b/testsuite/tests/callback/test1.ml @@ -1,9 +1,12 @@ (* TEST - include unix - modules = "test1_.c" - * libunix - ** bytecode - ** native + include unix; + modules = "test1_.c"; + libunix; + { + bytecode; + }{ + native; + } *) (**************************************************************************) diff --git a/testsuite/tests/callback/test2.ml b/testsuite/tests/callback/test2.ml index 87314864f2..168745a2a5 100644 --- a/testsuite/tests/callback/test2.ml +++ b/testsuite/tests/callback/test2.ml @@ -1,9 +1,12 @@ (* TEST - include unix - modules = "test2_.c" - * libunix - ** bytecode - ** native + include unix; + modules = "test2_.c"; + libunix; + { + bytecode; + }{ + native; + } *) (* Tests nested calls from C (main C) to OCaml (main OCaml) to C (caml_to_c) to diff --git a/testsuite/tests/callback/test3.ml b/testsuite/tests/callback/test3.ml index 6b4f64b739..ce40ae9141 100644 --- a/testsuite/tests/callback/test3.ml +++ b/testsuite/tests/callback/test3.ml @@ -1,9 +1,12 @@ (* TEST - include unix - modules = "test3_.c" - * libunix - ** bytecode - ** native + include unix; + modules = "test3_.c"; + libunix; + { + bytecode; + }{ + native; + } *) (* Tests nested calls from C (main C) to OCaml (main OCaml) to C (caml_to_c) to diff --git a/testsuite/tests/callback/test4.ml b/testsuite/tests/callback/test4.ml index 3c42317d7e..5f51c45158 100644 --- a/testsuite/tests/callback/test4.ml +++ b/testsuite/tests/callback/test4.ml @@ -1,9 +1,12 @@ (* TEST - include unix - modules = "test4_.c" - * libunix - ** bytecode - ** native + include unix; + modules = "test4_.c"; + libunix; + { + bytecode; + }{ + native; + } *) (* Tests nested calls from C (main C) to OCaml (main OCaml) to C (caml_to_c) to diff --git a/testsuite/tests/callback/test5.ml b/testsuite/tests/callback/test5.ml index 62fd8b9b0e..0249f93537 100644 --- a/testsuite/tests/callback/test5.ml +++ b/testsuite/tests/callback/test5.ml @@ -1,9 +1,12 @@ (* TEST - include unix - modules = "test5_.c" - * libunix - ** bytecode - ** native + include unix; + modules = "test5_.c"; + libunix; + { + bytecode; + }{ + native; + } *) (* Tests nested calls from C (main C) to OCaml (main OCaml) to C (caml_to_c) to diff --git a/testsuite/tests/callback/test6.ml b/testsuite/tests/callback/test6.ml index e3ff477f5b..4ecdafdf98 100644 --- a/testsuite/tests/callback/test6.ml +++ b/testsuite/tests/callback/test6.ml @@ -1,9 +1,12 @@ (* TEST - include unix - modules = "test6_.c" - * libunix - ** bytecode - ** native + include unix; + modules = "test6_.c"; + libunix; + { + bytecode; + }{ + native; + } *) (* Tests nested calls from C (main C) to OCaml (main OCaml) to C (caml_to_c) to diff --git a/testsuite/tests/callback/test7.ml b/testsuite/tests/callback/test7.ml index 8883a55f69..b607ec3cfb 100644 --- a/testsuite/tests/callback/test7.ml +++ b/testsuite/tests/callback/test7.ml @@ -1,9 +1,12 @@ (* TEST - include unix - modules = "test7_.c" - * libunix - ** bytecode - ** native + include unix; + modules = "test7_.c"; + libunix; + { + bytecode; + }{ + native; + } *) (* Tests nested calls from C (main C) to OCaml (main OCaml) to C (caml_to_c) to diff --git a/testsuite/tests/callback/test_finaliser_gc.ml b/testsuite/tests/callback/test_finaliser_gc.ml index c9c51cabb6..97c98cf89a 100644 --- a/testsuite/tests/callback/test_finaliser_gc.ml +++ b/testsuite/tests/callback/test_finaliser_gc.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) let z = ref (0, 1, 2, 3, 4, 5, 6, 7) let finaliser_pending = ref true diff --git a/testsuite/tests/callback/test_signalhandler.ml b/testsuite/tests/callback/test_signalhandler.ml index a2bbacee72..d94b17c036 100644 --- a/testsuite/tests/callback/test_signalhandler.ml +++ b/testsuite/tests/callback/test_signalhandler.ml @@ -1,9 +1,12 @@ (* TEST - include unix - modules = "test_signalhandler_.c" - * libunix - ** bytecode - ** native + include unix; + modules = "test_signalhandler_.c"; + libunix; + { + bytecode; + }{ + native; + } *) (**************************************************************************) diff --git a/testsuite/tests/compiler-libs/test_longident.ml b/testsuite/tests/compiler-libs/test_longident.ml index 33bf09ffec..d30060c7c7 100644 --- a/testsuite/tests/compiler-libs/test_longident.ml +++ b/testsuite/tests/compiler-libs/test_longident.ml @@ -1,7 +1,7 @@ (* TEST - flags = "-I ${ocamlsrcdir}/parsing" - include ocamlcommon - * expect + flags = "-I ${ocamlsrcdir}/parsing"; + include ocamlcommon; + expect; *) [@@@alert "-deprecated"] diff --git a/testsuite/tests/compiler-libs/test_untypeast.ml b/testsuite/tests/compiler-libs/test_untypeast.ml index 97775515fa..0a264642eb 100644 --- a/testsuite/tests/compiler-libs/test_untypeast.ml +++ b/testsuite/tests/compiler-libs/test_untypeast.ml @@ -1,8 +1,7 @@ (* TEST - flags = "-I ${ocamlsrcdir}/typing \ - -I ${ocamlsrcdir}/parsing" - include ocamlcommon - * expect + flags = "-I ${ocamlsrcdir}/typing -I ${ocamlsrcdir}/parsing"; + include ocamlcommon; + expect; *) let res = diff --git a/testsuite/tests/effects/backtrace.ml b/testsuite/tests/effects/backtrace.ml index 6257ba75c5..c76a070a14 100644 --- a/testsuite/tests/effects/backtrace.ml +++ b/testsuite/tests/effects/backtrace.ml @@ -1,6 +1,6 @@ -(* TEST - flags = "-g" - ocamlrunparam += ",b=1" +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + *) open Effect @@ -52,3 +52,8 @@ let main () = | _ -> None } let _ = main () + +(* TEST + flags = "-g"; + ocamlrunparam += ",b=1"; +*) diff --git a/testsuite/tests/effects/cmphash.ml b/testsuite/tests/effects/cmphash.ml index 78481d6404..397bc78fde 100644 --- a/testsuite/tests/effects/cmphash.ml +++ b/testsuite/tests/effects/cmphash.ml @@ -1,5 +1,4 @@ -(* TEST - *) +(* TEST *) open Effect open Effect.Deep diff --git a/testsuite/tests/effects/evenodd.ml b/testsuite/tests/effects/evenodd.ml index 035308b58f..c656bfb013 100644 --- a/testsuite/tests/effects/evenodd.ml +++ b/testsuite/tests/effects/evenodd.ml @@ -1,5 +1,4 @@ -(* TEST - *) +(* TEST *) open Effect open Effect.Deep diff --git a/testsuite/tests/effects/issue479.ml b/testsuite/tests/effects/issue479.ml index 228e098d2e..a960dcd8cc 100644 --- a/testsuite/tests/effects/issue479.ml +++ b/testsuite/tests/effects/issue479.ml @@ -1,5 +1,5 @@ (* TEST - * toplevel + toplevel; *) (* https://github.com/ocaml-multicore/ocaml-multicore/issues/479 *) diff --git a/testsuite/tests/effects/manylive.ml b/testsuite/tests/effects/manylive.ml index 96e25e23d8..edb4e7593d 100644 --- a/testsuite/tests/effects/manylive.ml +++ b/testsuite/tests/effects/manylive.ml @@ -1,5 +1,4 @@ -(* TEST - *) +(* TEST *) let f x = let a0 = ref 1 in diff --git a/testsuite/tests/effects/marshal.ml b/testsuite/tests/effects/marshal.ml index 89eee89457..c85c0eaec6 100644 --- a/testsuite/tests/effects/marshal.ml +++ b/testsuite/tests/effects/marshal.ml @@ -1,5 +1,4 @@ -(* TEST - *) +(* TEST *) open Effect open Effect.Deep diff --git a/testsuite/tests/effects/overflow.ml b/testsuite/tests/effects/overflow.ml index a187e9e10d..2bc5da91e3 100644 --- a/testsuite/tests/effects/overflow.ml +++ b/testsuite/tests/effects/overflow.ml @@ -1,5 +1,4 @@ -(* TEST - *) +(* TEST *) open Effect open Effect.Deep diff --git a/testsuite/tests/effects/partial.ml b/testsuite/tests/effects/partial.ml index 50e4b53cfc..64b7d496ac 100644 --- a/testsuite/tests/effects/partial.ml +++ b/testsuite/tests/effects/partial.ml @@ -1,5 +1,4 @@ -(* TEST - *) +(* TEST *) open Effect open Effect.Deep diff --git a/testsuite/tests/effects/reperform.ml b/testsuite/tests/effects/reperform.ml index 8aefdd0587..2ea45bcd4b 100644 --- a/testsuite/tests/effects/reperform.ml +++ b/testsuite/tests/effects/reperform.ml @@ -1,5 +1,4 @@ -(* TEST - *) +(* TEST *) open Effect open Effect.Deep diff --git a/testsuite/tests/effects/sched.ml b/testsuite/tests/effects/sched.ml index 3dc14a2cfc..ca97ecf736 100644 --- a/testsuite/tests/effects/sched.ml +++ b/testsuite/tests/effects/sched.ml @@ -1,5 +1,4 @@ -(* TEST - *) +(* TEST *) open Effect open Effect.Deep diff --git a/testsuite/tests/effects/shallow_state.ml b/testsuite/tests/effects/shallow_state.ml index 56c61b0c3c..90f27a8017 100644 --- a/testsuite/tests/effects/shallow_state.ml +++ b/testsuite/tests/effects/shallow_state.ml @@ -1,5 +1,4 @@ -(* TEST - *) +(* TEST *) open Effect open Effect.Shallow diff --git a/testsuite/tests/effects/shallow_state_io.ml b/testsuite/tests/effects/shallow_state_io.ml index 6b1fa649a7..b339ad96b5 100644 --- a/testsuite/tests/effects/shallow_state_io.ml +++ b/testsuite/tests/effects/shallow_state_io.ml @@ -1,5 +1,4 @@ -(* TEST - *) +(* TEST *) open Effect open Effect.Shallow diff --git a/testsuite/tests/effects/test1.ml b/testsuite/tests/effects/test1.ml index 5d05359f8a..c91b777696 100644 --- a/testsuite/tests/effects/test1.ml +++ b/testsuite/tests/effects/test1.ml @@ -1,5 +1,4 @@ -(* TEST - *) +(* TEST *) open Effect open Effect.Deep diff --git a/testsuite/tests/effects/test10.ml b/testsuite/tests/effects/test10.ml index 29c5f47f25..5e11b201ab 100644 --- a/testsuite/tests/effects/test10.ml +++ b/testsuite/tests/effects/test10.ml @@ -1,5 +1,4 @@ -(* TEST - *) +(* TEST *) open Effect open Effect.Deep diff --git a/testsuite/tests/effects/test11.ml b/testsuite/tests/effects/test11.ml index 6714473e0e..8d294c0b06 100644 --- a/testsuite/tests/effects/test11.ml +++ b/testsuite/tests/effects/test11.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) (* Tests RESUMETERM with extra_args != 0 in bytecode, by calling a handler with a tail-continue that returns a function *) diff --git a/testsuite/tests/effects/test2.ml b/testsuite/tests/effects/test2.ml index e9b8289bb2..877e1d3f07 100644 --- a/testsuite/tests/effects/test2.ml +++ b/testsuite/tests/effects/test2.ml @@ -1,5 +1,4 @@ -(* TEST - *) +(* TEST *) open Printf open Effect diff --git a/testsuite/tests/effects/test3.ml b/testsuite/tests/effects/test3.ml index d76130eaaa..1a64454399 100644 --- a/testsuite/tests/effects/test3.ml +++ b/testsuite/tests/effects/test3.ml @@ -1,5 +1,4 @@ -(* TEST - *) +(* TEST *) open Effect open Effect.Deep diff --git a/testsuite/tests/effects/test4.ml b/testsuite/tests/effects/test4.ml index f5cf78cbda..6bb57341f4 100644 --- a/testsuite/tests/effects/test4.ml +++ b/testsuite/tests/effects/test4.ml @@ -1,5 +1,4 @@ -(* TEST - *) +(* TEST *) open Effect open Effect.Deep diff --git a/testsuite/tests/effects/test5.ml b/testsuite/tests/effects/test5.ml index 33ed2c23ca..fc8e744870 100644 --- a/testsuite/tests/effects/test5.ml +++ b/testsuite/tests/effects/test5.ml @@ -1,5 +1,4 @@ -(* TEST - *) +(* TEST *) open Effect open Effect.Deep diff --git a/testsuite/tests/effects/test6.ml b/testsuite/tests/effects/test6.ml index 40574561bf..3a327446b5 100644 --- a/testsuite/tests/effects/test6.ml +++ b/testsuite/tests/effects/test6.ml @@ -1,5 +1,4 @@ -(* TEST - *) +(* TEST *) open Effect open Effect.Deep diff --git a/testsuite/tests/effects/unhandled_unlinked.ml b/testsuite/tests/effects/unhandled_unlinked.ml index bc2badb8e8..9ecfbecbc9 100644 --- a/testsuite/tests/effects/unhandled_unlinked.ml +++ b/testsuite/tests/effects/unhandled_unlinked.ml @@ -1,5 +1,5 @@ (* TEST - exit_status= "2" + exit_status = "2"; *) open Effect diff --git a/testsuite/tests/effects/used_cont.ml b/testsuite/tests/effects/used_cont.ml index 71a33388ec..bb4b8e6f87 100644 --- a/testsuite/tests/effects/used_cont.ml +++ b/testsuite/tests/effects/used_cont.ml @@ -1,5 +1,4 @@ -(* TEST - *) +(* TEST *) open Effect open Effect.Deep diff --git a/testsuite/tests/embedded/cmcaml.ml b/testsuite/tests/embedded/cmcaml.ml index 005b489cc9..f176cc57cf 100644 --- a/testsuite/tests/embedded/cmcaml.ml +++ b/testsuite/tests/embedded/cmcaml.ml @@ -1,5 +1,5 @@ (* TEST - modules = "cmstub.c cmmain.c" + modules = "cmstub.c cmmain.c"; *) (* OCaml part of the code *) diff --git a/testsuite/tests/ephe-c-api/test.ml b/testsuite/tests/ephe-c-api/test.ml index ff1646835a..e84c012ace 100644 --- a/testsuite/tests/ephe-c-api/test.ml +++ b/testsuite/tests/ephe-c-api/test.ml @@ -1,7 +1,7 @@ (* TEST - modules = "stubs.c" - * skip - reason = "port the new Ephemeron C-api to multicore : https://github.com/ocaml/ocaml/pull/676" + modules = "stubs.c"; + reason = "port the new Ephemeron C-api to multicore : https://github.com/ocaml/ocaml/pull/676"; + skip; *) (* C version of ephetest.ml *) diff --git a/testsuite/tests/exotic-syntax/exotic.ml b/testsuite/tests/exotic-syntax/exotic.ml index 94666e7fab..b0c8834798 100644 --- a/testsuite/tests/exotic-syntax/exotic.ml +++ b/testsuite/tests/exotic-syntax/exotic.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) (* Exotic OCaml syntax constructs found in the manual that are not *) (* used in the source of the OCaml distribution (even in the tests). *) diff --git a/testsuite/tests/extension-constructor/test.ml b/testsuite/tests/extension-constructor/test.ml index 227f420a96..b4cc334c8a 100644 --- a/testsuite/tests/extension-constructor/test.ml +++ b/testsuite/tests/extension-constructor/test.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) type t = .. diff --git a/testsuite/tests/flambda/afl_lazy.ml b/testsuite/tests/flambda/afl_lazy.ml index fd5178dac8..657b0d20c2 100644 --- a/testsuite/tests/flambda/afl_lazy.ml +++ b/testsuite/tests/flambda/afl_lazy.ml @@ -1,7 +1,7 @@ (* TEST - * flambda - ** native - ocamlopt_flags = "-O3 -afl-instrument" + flambda; + ocamlopt_flags = "-O3 -afl-instrument"; + native; *) let f l = diff --git a/testsuite/tests/flambda/approx_meet.ml b/testsuite/tests/flambda/approx_meet.ml index c8a1276990..4445ae84bc 100644 --- a/testsuite/tests/flambda/approx_meet.ml +++ b/testsuite/tests/flambda/approx_meet.ml @@ -1,6 +1,9 @@ (* TEST - * flambda - * native + { + flambda; + }{ + native; + } *) (* from GPR#1794 *) diff --git a/testsuite/tests/flambda/gpr2239.ml b/testsuite/tests/flambda/gpr2239.ml index 22c6555e08..f39ba3eb2a 100644 --- a/testsuite/tests/flambda/gpr2239.ml +++ b/testsuite/tests/flambda/gpr2239.ml @@ -1,6 +1,9 @@ (* TEST - * flambda - * native + { + flambda; + }{ + native; + } *) let do_something () = diff --git a/testsuite/tests/flambda/gpr998.ml b/testsuite/tests/flambda/gpr998.ml index dfb06833ec..b1cb64baa1 100644 --- a/testsuite/tests/flambda/gpr998.ml +++ b/testsuite/tests/flambda/gpr998.ml @@ -1,5 +1,5 @@ (* TEST - ocamlopt_flags = "-unbox-closures" + ocamlopt_flags = "-unbox-closures"; *) (* This test attempts to check that unused closures are not deleted diff --git a/testsuite/tests/flambda/specialise.ml b/testsuite/tests/flambda/specialise.ml index b5e80c7b99..fc2a57eeb0 100644 --- a/testsuite/tests/flambda/specialise.ml +++ b/testsuite/tests/flambda/specialise.ml @@ -1,7 +1,7 @@ (* TEST - * flambda - ** native - ocamlopt_flags = "-O2 -inline-call-cost 1=20 -unbox-closures" + flambda; + ocamlopt_flags = "-O2 -inline-call-cost 1=20 -unbox-closures"; + native; *) let hide_until_round_2 init_in_hide f_in_hide = diff --git a/testsuite/tests/float-unboxing/float_subst_boxed_number.ml b/testsuite/tests/float-unboxing/float_subst_boxed_number.ml index 459e3eba96..fa6ebb268d 100644 --- a/testsuite/tests/float-unboxing/float_subst_boxed_number.ml +++ b/testsuite/tests/float-unboxing/float_subst_boxed_number.ml @@ -1,9 +1,9 @@ (* TEST - include config - flags = "-w -55" - ocamlc_flags = "config.cmo" - ocamlopt_flags = "-inline 20 config.cmx" - * native + include config; + flags = "-w -55"; + ocamlc_flags = "config.cmo"; + ocamlopt_flags = "-inline 20 config.cmx"; + native; *) let eliminate_intermediate_float_record () = diff --git a/testsuite/tests/float-unboxing/unbox_under_assign.ml b/testsuite/tests/float-unboxing/unbox_under_assign.ml index 46a6a18ce3..9365875f94 100644 --- a/testsuite/tests/float-unboxing/unbox_under_assign.ml +++ b/testsuite/tests/float-unboxing/unbox_under_assign.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) module Float = struct type _ t = diff --git a/testsuite/tests/formats-transition/deprecated_unsigned_printers.ml b/testsuite/tests/formats-transition/deprecated_unsigned_printers.ml index 21f4bf4226..76af1fbdf6 100644 --- a/testsuite/tests/formats-transition/deprecated_unsigned_printers.ml +++ b/testsuite/tests/formats-transition/deprecated_unsigned_printers.ml @@ -1,5 +1,5 @@ (* TEST - * toplevel + toplevel; *) (* %n, %l, %N and %L have a scanf-specific semantics, but are supposed diff --git a/testsuite/tests/formats-transition/ignored_scan_counters.ml b/testsuite/tests/formats-transition/ignored_scan_counters.ml index bc625511d0..a597532f80 100644 --- a/testsuite/tests/formats-transition/ignored_scan_counters.ml +++ b/testsuite/tests/formats-transition/ignored_scan_counters.ml @@ -1,5 +1,5 @@ (* TEST - * toplevel + toplevel; *) (* Benoit's patch did not support %_[nlNL]; test their behavior *) diff --git a/testsuite/tests/formats-transition/legacy_incompatible_flags.ml b/testsuite/tests/formats-transition/legacy_incompatible_flags.ml index 91b0f6f07f..b9978026ce 100644 --- a/testsuite/tests/formats-transition/legacy_incompatible_flags.ml +++ b/testsuite/tests/formats-transition/legacy_incompatible_flags.ml @@ -1,6 +1,6 @@ (* TEST - flags = "-no-strict-formats" - * toplevel + flags = "-no-strict-formats"; + toplevel; *) (* the legacy parser ignores flags on formatters on which they make no diff --git a/testsuite/tests/formats-transition/legacy_unfinished_modifiers.ml b/testsuite/tests/formats-transition/legacy_unfinished_modifiers.ml index 9bbaa178a3..c03de65e20 100644 --- a/testsuite/tests/formats-transition/legacy_unfinished_modifiers.ml +++ b/testsuite/tests/formats-transition/legacy_unfinished_modifiers.ml @@ -1,6 +1,6 @@ (* TEST - flags = "-no-strict-formats" - * toplevel + flags = "-no-strict-formats"; + toplevel; *) (* test whether padding modifiers are accepted without any padding diff --git a/testsuite/tests/formatting/errors_batch.ml b/testsuite/tests/formatting/errors_batch.ml index abf4513da1..6d5bf4611c 100644 --- a/testsuite/tests/formatting/errors_batch.ml +++ b/testsuite/tests/formatting/errors_batch.ml @@ -1,5 +1,5 @@ (* TEST - include ocamlcommon + include ocamlcommon; *) let () = diff --git a/testsuite/tests/formatting/margins.ml b/testsuite/tests/formatting/margins.ml index 036288890e..baa1dace63 100644 --- a/testsuite/tests/formatting/margins.ml +++ b/testsuite/tests/formatting/margins.ml @@ -1,5 +1,5 @@ (* TEST - * toplevel + toplevel; *) let () = Format.pp_set_margin Format.std_formatter 20;; diff --git a/testsuite/tests/formatting/test_locations.ml b/testsuite/tests/formatting/test_locations.ml index b821f626ae..87bce8c613 100644 --- a/testsuite/tests/formatting/test_locations.ml +++ b/testsuite/tests/formatting/test_locations.ml @@ -1,20 +1,37 @@ -(* TEST -compile_only="true" -* setup-ocamlc.byte-build-env -** ocamlc.byte -flags="-g -dno-unique-ids -dno-locations -dsource -dparsetree -dtypedtree -dlambda" -*** check-ocamlc.byte-output -compiler_reference = - "${test_source_directory}/test_locations.dno-locations.ocamlc.reference" +(* TEST_BELOW +Filler_text_a +dded_to_preserve_locations_wh +ile_translatin +g_from_old_syntax__Filler_text_added_to_preserve_locations_while_translating_from_o +ld_syntax__Filler_text_added +_to_preserve_locatio +ns_while_translating_from_old_syntax__Filler_text_added_to_preserve_locati -* setup-ocamlc.byte-build-env -** ocamlc.byte -flags="-g -dno-unique-ids -dlocations -dsource -dparsetree -dtypedtree -dlambda" -*** check-ocamlc.byte-output -compiler_reference = - "${test_source_directory}/test_locations.dlocations.ocamlc.reference" +ons_while_translating_from_ol +d_syntax__Fill +er_text_added_to_preserve_locations_while_translating_from_old_syntax__Filler_te +xt_added_to_preserve_locatio +ns_while_translating +_from_old_syntax__Filler_text_added_to_preserve_locations_while_transla *) let rec fib = function | 0 | 1 -> 1 | n -> fib (n - 1) + fib (n - 2) ;; + +(* TEST + compile_only = "true"; + { + setup-ocamlc.byte-build-env; + flags = "-g -dno-unique-ids -dno-locations -dsource -dparsetree -dtypedtree -dlambda"; + ocamlc.byte; + compiler_reference = "${test_source_directory}/test_locations.dno-locations.ocamlc.reference"; + check-ocamlc.byte-output; + }{ + setup-ocamlc.byte-build-env; + flags = "-g -dno-unique-ids -dlocations -dsource -dparsetree -dtypedtree -dlambda"; + ocamlc.byte; + compiler_reference = "${test_source_directory}/test_locations.dlocations.ocamlc.reference"; + check-ocamlc.byte-output; + } +*) diff --git a/testsuite/tests/frame-pointers/c_call.ml b/testsuite/tests/frame-pointers/c_call.ml index c2493b3a99..7d48b4947d 100644 --- a/testsuite/tests/frame-pointers/c_call.ml +++ b/testsuite/tests/frame-pointers/c_call.ml @@ -1,10 +1,8 @@ (* TEST - -* frame_pointers -** native -readonly_files = "fp_backtrace.c c_call_.c" -all_modules = "${readonly_files} c_call.ml" - + frame_pointers; + readonly_files = "fp_backtrace.c c_call_.c"; + all_modules = "${readonly_files} c_call.ml"; + native; *) external fp_backtrace : unit -> unit = "fp_backtrace" diff --git a/testsuite/tests/frame-pointers/effects.ml b/testsuite/tests/frame-pointers/effects.ml index e14633a374..2aa7012606 100644 --- a/testsuite/tests/frame-pointers/effects.ml +++ b/testsuite/tests/frame-pointers/effects.ml @@ -1,10 +1,8 @@ (* TEST - -* frame_pointers -** native -readonly_files = "fp_backtrace.c" -all_modules = "${readonly_files} effects.ml" - + frame_pointers; + readonly_files = "fp_backtrace.c"; + all_modules = "${readonly_files} effects.ml"; + native; *) open Printf diff --git a/testsuite/tests/frame-pointers/exception_handler.ml b/testsuite/tests/frame-pointers/exception_handler.ml index 575f7329bf..6bf5bf470d 100644 --- a/testsuite/tests/frame-pointers/exception_handler.ml +++ b/testsuite/tests/frame-pointers/exception_handler.ml @@ -1,10 +1,8 @@ (* TEST - -* frame_pointers -** native -readonly_files = "fp_backtrace.c" -all_modules = "${readonly_files} exception_handler.ml" - + frame_pointers; + readonly_files = "fp_backtrace.c"; + all_modules = "${readonly_files} exception_handler.ml"; + native; *) (* https://github.com/ocaml/ocaml/pull/11031 *) diff --git a/testsuite/tests/frame-pointers/reperform.ml b/testsuite/tests/frame-pointers/reperform.ml index 1af8452e5f..ec5393907c 100644 --- a/testsuite/tests/frame-pointers/reperform.ml +++ b/testsuite/tests/frame-pointers/reperform.ml @@ -1,11 +1,8 @@ (* TEST - -* frame_pointers -** native - -readonly_files = "fp_backtrace.c" -all_modules = "${readonly_files} reperform.ml" - + frame_pointers; + readonly_files = "fp_backtrace.c"; + all_modules = "${readonly_files} reperform.ml"; + native; *) open Effect diff --git a/testsuite/tests/frame-pointers/stack_realloc.ml b/testsuite/tests/frame-pointers/stack_realloc.ml index 79e70c2add..fc4e9e9d3b 100644 --- a/testsuite/tests/frame-pointers/stack_realloc.ml +++ b/testsuite/tests/frame-pointers/stack_realloc.ml @@ -1,11 +1,8 @@ (* TEST - -* frame_pointers -** native - -readonly_files = "fp_backtrace.c stack_realloc_.c" -all_modules = "${readonly_files} stack_realloc.ml" - + frame_pointers; + readonly_files = "fp_backtrace.c stack_realloc_.c"; + all_modules = "${readonly_files} stack_realloc.ml"; + native; *) open Effect diff --git a/testsuite/tests/frame-pointers/stack_realloc2.ml b/testsuite/tests/frame-pointers/stack_realloc2.ml index a3d21bf2bf..a4aea249ea 100644 --- a/testsuite/tests/frame-pointers/stack_realloc2.ml +++ b/testsuite/tests/frame-pointers/stack_realloc2.ml @@ -1,11 +1,8 @@ (* TEST - -* frame_pointers -** native - -readonly_files = "fp_backtrace.c stack_realloc_.c" -all_modules = "${readonly_files} stack_realloc2.ml" - + frame_pointers; + readonly_files = "fp_backtrace.c stack_realloc_.c"; + all_modules = "${readonly_files} stack_realloc2.ml"; + native; *) open Effect diff --git a/testsuite/tests/functors/functors.ml b/testsuite/tests/functors/functors.ml index 3e40fc6147..0518f71844 100644 --- a/testsuite/tests/functors/functors.ml +++ b/testsuite/tests/functors/functors.ml @@ -1,8 +1,8 @@ (* TEST - * setup-ocamlc.byte-build-env - ** ocamlc.byte - flags = "-dlambda -dno-unique-ids" - *** check-ocamlc.byte-output + setup-ocamlc.byte-build-env; + flags = "-dlambda -dno-unique-ids"; + ocamlc.byte; + check-ocamlc.byte-output; *) module type S = sig diff --git a/testsuite/tests/gc-roots/globroots.ml b/testsuite/tests/gc-roots/globroots.ml index 56d1586331..52283d3401 100644 --- a/testsuite/tests/gc-roots/globroots.ml +++ b/testsuite/tests/gc-roots/globroots.ml @@ -1,5 +1,5 @@ (* TEST - modules = "globrootsprim.c" + modules = "globrootsprim.c"; *) module type GLOBREF = sig diff --git a/testsuite/tests/gc-roots/globroots_parallel.ml b/testsuite/tests/gc-roots/globroots_parallel.ml index 9ef88575b2..3a42308f72 100644 --- a/testsuite/tests/gc-roots/globroots_parallel.ml +++ b/testsuite/tests/gc-roots/globroots_parallel.ml @@ -1,6 +1,6 @@ (* TEST - flags += " -w a " - modules = "globrootsprim.c globroots.ml" + flags += " -w a "; + modules = "globrootsprim.c globroots.ml"; *) open Globroots diff --git a/testsuite/tests/gc-roots/globroots_parallel_spawn_burn.ml b/testsuite/tests/gc-roots/globroots_parallel_spawn_burn.ml index c8b36098ac..8acd6913bd 100644 --- a/testsuite/tests/gc-roots/globroots_parallel_spawn_burn.ml +++ b/testsuite/tests/gc-roots/globroots_parallel_spawn_burn.ml @@ -1,6 +1,6 @@ (* TEST - flags += " -w a " - modules = "globrootsprim.c globroots.ml" + flags += " -w a "; + modules = "globrootsprim.c globroots.ml"; *) open Globroots diff --git a/testsuite/tests/gc-roots/globroots_sequential.ml b/testsuite/tests/gc-roots/globroots_sequential.ml index 6bf995bf96..8c9f82e257 100644 --- a/testsuite/tests/gc-roots/globroots_sequential.ml +++ b/testsuite/tests/gc-roots/globroots_sequential.ml @@ -1,6 +1,6 @@ (* TEST - flags += " -w a " - modules = "globrootsprim.c globroots.ml" + flags += " -w a "; + modules = "globrootsprim.c globroots.ml"; *) open Globroots diff --git a/testsuite/tests/generalized-open/accepted_expect.ml b/testsuite/tests/generalized-open/accepted_expect.ml index 01c94c275b..a373e0cfde 100644 --- a/testsuite/tests/generalized-open/accepted_expect.ml +++ b/testsuite/tests/generalized-open/accepted_expect.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) open Set.Make(String);; diff --git a/testsuite/tests/generalized-open/clambda_optim.ml b/testsuite/tests/generalized-open/clambda_optim.ml index d7ca317ea6..9d24784f85 100644 --- a/testsuite/tests/generalized-open/clambda_optim.ml +++ b/testsuite/tests/generalized-open/clambda_optim.ml @@ -1,12 +1,9 @@ (* TEST - -compile_only = "true" - -* no-flambda -** setup-ocamlopt.byte-build-env -*** ocamlopt.byte -**** check-ocamlopt.byte-output - + compile_only = "true"; + no-flambda; + setup-ocamlopt.byte-build-env; + ocamlopt.byte; + check-ocamlopt.byte-output; *) module Stable = struct diff --git a/testsuite/tests/generalized-open/expansiveness.ml b/testsuite/tests/generalized-open/expansiveness.ml index b2a55012f4..0e833d74e9 100644 --- a/testsuite/tests/generalized-open/expansiveness.ml +++ b/testsuite/tests/generalized-open/expansiveness.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module Fn = struct diff --git a/testsuite/tests/generalized-open/funct_body.ml b/testsuite/tests/generalized-open/funct_body.ml index 4490f77392..d20f4d2c53 100644 --- a/testsuite/tests/generalized-open/funct_body.ml +++ b/testsuite/tests/generalized-open/funct_body.ml @@ -1,8 +1,8 @@ -(* TEST -* setup-ocamlc.byte-build-env -** ocamlc.byte -ocamlc_byte_exit_status = "2" -** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + *) module type T = sig @@ -45,3 +45,13 @@ module O = F(M) let () = O.f N.x + +(* TEST + setup-ocamlc.byte-build-env; + { + ocamlc_byte_exit_status = "2"; + ocamlc.byte; + }{ + check-ocamlc.byte-output; + } +*) diff --git a/testsuite/tests/generalized-open/gpr1506.ml b/testsuite/tests/generalized-open/gpr1506.ml index a6c8daa105..7663e2d77f 100644 --- a/testsuite/tests/generalized-open/gpr1506.ml +++ b/testsuite/tests/generalized-open/gpr1506.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type t = A diff --git a/testsuite/tests/generalized-open/pr10048.ml b/testsuite/tests/generalized-open/pr10048.ml index d6f29322b0..8284bae912 100644 --- a/testsuite/tests/generalized-open/pr10048.ml +++ b/testsuite/tests/generalized-open/pr10048.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module Ext (X : sig type 'a t end) = struct type t = T : 'a X.t -> t diff --git a/testsuite/tests/generalized-open/shadowing.ml b/testsuite/tests/generalized-open/shadowing.ml index 589807d367..37a6234662 100644 --- a/testsuite/tests/generalized-open/shadowing.ml +++ b/testsuite/tests/generalized-open/shadowing.ml @@ -1,8 +1,11 @@ (* TEST -* setup-ocamlc.byte-build-env -** ocamlc.byte -ocamlc_byte_exit_status = "0" -** check-ocamlc.byte-output + setup-ocamlc.byte-build-env; + { + ocamlc_byte_exit_status = "0"; + ocamlc.byte; + }{ + check-ocamlc.byte-output; + } *) module Make_sure_val : sig diff --git a/testsuite/tests/generated-parse-errors/errors.ml b/testsuite/tests/generated-parse-errors/errors.ml index c1f11f4416..19cf705a07 100644 --- a/testsuite/tests/generated-parse-errors/errors.ml +++ b/testsuite/tests/generated-parse-errors/errors.ml @@ -1,5 +1,5 @@ (* TEST - * toplevel + toplevel; *) #0 "use_file: HASH LIDENT TRUE WITH" # lident true with diff --git a/testsuite/tests/int64-unboxing/test.ml b/testsuite/tests/int64-unboxing/test.ml index d35e52147a..7e00b54ee3 100644 --- a/testsuite/tests/int64-unboxing/test.ml +++ b/testsuite/tests/int64-unboxing/test.ml @@ -1,6 +1,6 @@ (* TEST - modules = "stubs.c" - * native + modules = "stubs.c"; + native; *) external ( + ) : int64 -> int64 -> int64 diff --git a/testsuite/tests/lazy/lazy1.ml b/testsuite/tests/lazy/lazy1.ml index f88e93da69..e2e0a2a78a 100644 --- a/testsuite/tests/lazy/lazy1.ml +++ b/testsuite/tests/lazy/lazy1.ml @@ -1,5 +1,5 @@ (* TEST - ocamlopt_flags += " -O3 " + ocamlopt_flags += " -O3 "; *) (* Mantis 7301, due to A. Frisch *) diff --git a/testsuite/tests/lazy/lazy2.ml b/testsuite/tests/lazy/lazy2.ml index cccbd96d71..e386b97d6a 100644 --- a/testsuite/tests/lazy/lazy2.ml +++ b/testsuite/tests/lazy/lazy2.ml @@ -1,5 +1,5 @@ (* TEST - ocamlopt_flags += " -O3 " + ocamlopt_flags += " -O3 "; *) open Domain diff --git a/testsuite/tests/lazy/lazy3.ml b/testsuite/tests/lazy/lazy3.ml index a22a0893b9..ff20beddd2 100644 --- a/testsuite/tests/lazy/lazy3.ml +++ b/testsuite/tests/lazy/lazy3.ml @@ -1,5 +1,5 @@ (* TEST - ocamlopt_flags += " -O3 " + ocamlopt_flags += " -O3 "; *) let f count = diff --git a/testsuite/tests/lazy/lazy4.ml b/testsuite/tests/lazy/lazy4.ml index 3988318c79..9d4acdd99f 100644 --- a/testsuite/tests/lazy/lazy4.ml +++ b/testsuite/tests/lazy/lazy4.ml @@ -1,5 +1,5 @@ (* TEST - ocamlopt_flags += " -O3 " + ocamlopt_flags += " -O3 "; *) let r = ref None diff --git a/testsuite/tests/lazy/lazy5.ml b/testsuite/tests/lazy/lazy5.ml index 217b84175e..4a8ac59fff 100644 --- a/testsuite/tests/lazy/lazy5.ml +++ b/testsuite/tests/lazy/lazy5.ml @@ -1,5 +1,5 @@ (* TEST - ocamlopt_flags += " -O3 " + ocamlopt_flags += " -O3 "; *) let rec safe_force l = try Lazy.force l with diff --git a/testsuite/tests/lazy/lazy6.ml b/testsuite/tests/lazy/lazy6.ml index 098848769a..9cad998ba3 100644 --- a/testsuite/tests/lazy/lazy6.ml +++ b/testsuite/tests/lazy/lazy6.ml @@ -1,5 +1,5 @@ (* TEST - ocamlopt_flags += " -O3 " + ocamlopt_flags += " -O3 "; *) let flag1 = Atomic.make false diff --git a/testsuite/tests/lazy/lazy7.ml b/testsuite/tests/lazy/lazy7.ml index 6c96f32907..ceae7061c9 100644 --- a/testsuite/tests/lazy/lazy7.ml +++ b/testsuite/tests/lazy/lazy7.ml @@ -1,5 +1,5 @@ (* TEST - ocamlopt_flags += " -O3 " + ocamlopt_flags += " -O3 "; *) let num_domains = 4 diff --git a/testsuite/tests/lazy/lazy8.ml b/testsuite/tests/lazy/lazy8.ml index c9b5781617..1ecf578fad 100644 --- a/testsuite/tests/lazy/lazy8.ml +++ b/testsuite/tests/lazy/lazy8.ml @@ -1,5 +1,5 @@ (* TEST - ocamlopt_flags += " -O3 " + ocamlopt_flags += " -O3 "; *) exception E diff --git a/testsuite/tests/lazy/minor_major_force.ml b/testsuite/tests/lazy/minor_major_force.ml index 37f367a9c7..f32fa66421 100644 --- a/testsuite/tests/lazy/minor_major_force.ml +++ b/testsuite/tests/lazy/minor_major_force.ml @@ -1,5 +1,5 @@ (* TEST - ocamlopt_flags += " -O3 " + ocamlopt_flags += " -O3 "; *) (* diff --git a/testsuite/tests/let-syntax/let_syntax.ml b/testsuite/tests/let-syntax/let_syntax.ml index 9824bb5309..67ca3c6fcc 100644 --- a/testsuite/tests/let-syntax/let_syntax.ml +++ b/testsuite/tests/let-syntax/let_syntax.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) let id x = x diff --git a/testsuite/tests/letrec-check/basic.ml b/testsuite/tests/letrec-check/basic.ml index 595212802f..caa8c238ed 100644 --- a/testsuite/tests/letrec-check/basic.ml +++ b/testsuite/tests/letrec-check/basic.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) let rec x = (x; ());; diff --git a/testsuite/tests/letrec-check/extension_constructor.ml b/testsuite/tests/letrec-check/extension_constructor.ml index 93171ae1dc..007be5b8dd 100644 --- a/testsuite/tests/letrec-check/extension_constructor.ml +++ b/testsuite/tests/letrec-check/extension_constructor.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* Example from Stephen Dolan. diff --git a/testsuite/tests/letrec-check/flat_float_array.ml b/testsuite/tests/letrec-check/flat_float_array.ml index e49064cc4d..56912f44c8 100644 --- a/testsuite/tests/letrec-check/flat_float_array.ml +++ b/testsuite/tests/letrec-check/flat_float_array.ml @@ -1,6 +1,6 @@ (* TEST - * flat-float-array - ** expect + flat-float-array; + expect; *) (* When the -flat-float-array optimization is active (standard in diff --git a/testsuite/tests/letrec-check/float_unboxing.ml b/testsuite/tests/letrec-check/float_unboxing.ml index 6ef268f85d..142841312e 100644 --- a/testsuite/tests/letrec-check/float_unboxing.ml +++ b/testsuite/tests/letrec-check/float_unboxing.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* This program is a minimal example which segfault if diff --git a/testsuite/tests/letrec-check/labels.ml b/testsuite/tests/letrec-check/labels.ml index e8b28342b8..46f8bed903 100644 --- a/testsuite/tests/letrec-check/labels.ml +++ b/testsuite/tests/letrec-check/labels.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) let f ~x () = x ();; diff --git a/testsuite/tests/letrec-check/lazy_.ml b/testsuite/tests/letrec-check/lazy_.ml index 3bec9ec77d..5af54bfe37 100644 --- a/testsuite/tests/letrec-check/lazy_.ml +++ b/testsuite/tests/letrec-check/lazy_.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) let rec a = lazy b and b = 3;; diff --git a/testsuite/tests/letrec-check/modules.ml b/testsuite/tests/letrec-check/modules.ml index fc55f76b66..af4e3aeb58 100644 --- a/testsuite/tests/letrec-check/modules.ml +++ b/testsuite/tests/letrec-check/modules.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) let rec x = let module M = struct let f = x end in ();; diff --git a/testsuite/tests/letrec-check/no_flat_float_array.ml b/testsuite/tests/letrec-check/no_flat_float_array.ml index 394669bfdc..fd952c4df8 100644 --- a/testsuite/tests/letrec-check/no_flat_float_array.ml +++ b/testsuite/tests/letrec-check/no_flat_float_array.ml @@ -1,6 +1,6 @@ (* TEST - * no-flat-float-array - ** expect + no-flat-float-array; + expect; *) (* See float_block_disallowed.ml for explanations. diff --git a/testsuite/tests/letrec-check/objects.ml b/testsuite/tests/letrec-check/objects.ml index a223450e49..c3066290b0 100644 --- a/testsuite/tests/letrec-check/objects.ml +++ b/testsuite/tests/letrec-check/objects.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) class c = object end diff --git a/testsuite/tests/letrec-check/pr7215.ml b/testsuite/tests/letrec-check/pr7215.ml index 0a13bd6e83..487cdc3ede 100644 --- a/testsuite/tests/letrec-check/pr7215.ml +++ b/testsuite/tests/letrec-check/pr7215.ml @@ -1,5 +1,5 @@ (* TEST - * toplevel + toplevel; *) (* From Stephen Dolan *) diff --git a/testsuite/tests/letrec-check/pr7231.ml b/testsuite/tests/letrec-check/pr7231.ml index b2ddf3c2b3..7625e4df99 100644 --- a/testsuite/tests/letrec-check/pr7231.ml +++ b/testsuite/tests/letrec-check/pr7231.ml @@ -1,5 +1,9 @@ -(* TEST - * toplevel +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) *) let rec r = let rec x () = r and y () = x () in y () in r "oops";; + +(* TEST + toplevel; +*) diff --git a/testsuite/tests/letrec-check/pr7706.ml b/testsuite/tests/letrec-check/pr7706.ml index 87403cd5a2..f566bff7ee 100644 --- a/testsuite/tests/letrec-check/pr7706.ml +++ b/testsuite/tests/letrec-check/pr7706.ml @@ -1,8 +1,12 @@ -(* TEST - * toplevel +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) *) let rec x = let y = if false then (fun z -> 1) else (fun z -> x 4 + 1) in y;; let () = ignore (x 42);; + +(* TEST + toplevel; +*) diff --git a/testsuite/tests/letrec-check/records.ml b/testsuite/tests/letrec-check/records.ml index db11d41eb7..2076fd227b 100644 --- a/testsuite/tests/letrec-check/records.ml +++ b/testsuite/tests/letrec-check/records.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type t = { x : int; self : t };; [%%expect {| diff --git a/testsuite/tests/letrec-check/unboxed.ml b/testsuite/tests/letrec-check/unboxed.ml index 7c04199ec9..8ef457f3ff 100644 --- a/testsuite/tests/letrec-check/unboxed.ml +++ b/testsuite/tests/letrec-check/unboxed.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type r = R of r list [@@unboxed] diff --git a/testsuite/tests/lexing/comments.ml b/testsuite/tests/lexing/comments.ml index a7c9f2758d..99701d9608 100644 --- a/testsuite/tests/lexing/comments.ml +++ b/testsuite/tests/lexing/comments.ml @@ -1,5 +1,5 @@ (* TEST - * toplevel + toplevel; *) (* "*)" *) diff --git a/testsuite/tests/lexing/escape.ml b/testsuite/tests/lexing/escape.ml index bcb753131a..8e6abbad05 100644 --- a/testsuite/tests/lexing/escape.ml +++ b/testsuite/tests/lexing/escape.ml @@ -1,5 +1,5 @@ -(* TEST - * toplevel +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) *) (* Errors *) @@ -9,3 +9,7 @@ let invalid = "\999" ;; let invalid = "\o777" ;; let invalid = "\o77" ;; let invalid = "\o99" ;; + +(* TEST + toplevel; +*) diff --git a/testsuite/tests/lexing/uchar_esc.ml b/testsuite/tests/lexing/uchar_esc.ml index 3e7b5379da..77e328acd4 100644 --- a/testsuite/tests/lexing/uchar_esc.ml +++ b/testsuite/tests/lexing/uchar_esc.ml @@ -1,5 +1,5 @@ (* TEST - * toplevel + toplevel; *) (* Correct escapes and their encoding *) diff --git a/testsuite/tests/lf_skiplist/test.ml b/testsuite/tests/lf_skiplist/test.ml index f3b11bf411..9a4a19cee7 100644 --- a/testsuite/tests/lf_skiplist/test.ml +++ b/testsuite/tests/lf_skiplist/test.ml @@ -1,5 +1,5 @@ (* TEST - modules = "stubs.c" + modules = "stubs.c"; *) external test_skiplist_serial : unit -> unit = "test_skiplist_serial" diff --git a/testsuite/tests/lf_skiplist/test_parallel.ml b/testsuite/tests/lf_skiplist/test_parallel.ml index ac02717889..1bbd8166bc 100644 --- a/testsuite/tests/lf_skiplist/test_parallel.ml +++ b/testsuite/tests/lf_skiplist/test_parallel.ml @@ -1,5 +1,5 @@ (* TEST - modules = "stubs.c" + modules = "stubs.c"; *) external init_skiplist : unit -> unit = "init_skiplist" diff --git a/testsuite/tests/lib-arg/test_rest_all.ml b/testsuite/tests/lib-arg/test_rest_all.ml index b0ac3c1eb5..81475013c1 100644 --- a/testsuite/tests/lib-arg/test_rest_all.ml +++ b/testsuite/tests/lib-arg/test_rest_all.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type arg = AString of string | ARest of string | ARest_all of string list diff --git a/testsuite/tests/lib-arg/testerror.ml b/testsuite/tests/lib-arg/testerror.ml index 6bcf0fdeb8..0bbd5dce9b 100644 --- a/testsuite/tests/lib-arg/testerror.ml +++ b/testsuite/tests/lib-arg/testerror.ml @@ -1,5 +1,5 @@ (* TEST - * native + native; *) (** Test that the right message errors are emitted by Arg *) diff --git a/testsuite/tests/lib-array/test_array.ml b/testsuite/tests/lib-array/test_array.ml index b3399e98de..c5b6143db6 100644 --- a/testsuite/tests/lib-array/test_array.ml +++ b/testsuite/tests/lib-array/test_array.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) let a = Array.make 8 None;; diff --git a/testsuite/tests/lib-bigarray-2/bigarrcml.ml b/testsuite/tests/lib-bigarray-2/bigarrcml.ml index 27f83ffae4..643fb86a9f 100644 --- a/testsuite/tests/lib-bigarray-2/bigarrcml.ml +++ b/testsuite/tests/lib-bigarray-2/bigarrcml.ml @@ -1,7 +1,5 @@ (* TEST - -modules = "bigarrcstub.c" - + modules = "bigarrcstub.c"; *) open Bigarray diff --git a/testsuite/tests/lib-bigarray-2/bigarrfml.ml b/testsuite/tests/lib-bigarray-2/bigarrfml.ml index a31e545c1a..05ba7b2771 100644 --- a/testsuite/tests/lib-bigarray-2/bigarrfml.ml +++ b/testsuite/tests/lib-bigarray-2/bigarrfml.ml @@ -1,31 +1,29 @@ (* TEST - -readonly_files = "bigarrf.f bigarrfstub.c" -last_flags = "-cclib -lgfortran" - -* script -script = "sh ${test_source_directory}/has-gfortran.sh" - -** setup-ocamlc.byte-build-env -*** script -script = "sh ${test_source_directory}/call-gfortran.sh ${cc} -c bigarrf.f" -**** ocamlc.byte -all_modules = "bigarrf.o bigarrfstub.c bigarrfml.ml" -***** run -output = "${test_build_directory}/program-output" -stdout = "${output}" -****** check-program-output - -** setup-ocamlopt.byte-build-env -*** script -script = "sh ${test_source_directory}/call-gfortran.sh ${cc} -c bigarrf.f" -**** ocamlopt.byte -all_modules = "bigarrf.o bigarrfstub.c bigarrfml.ml" -***** run -output = "${test_build_directory}/program-output" -stdout = "${output}" -****** check-program-output - + readonly_files = "bigarrf.f bigarrfstub.c"; + last_flags = "-cclib -lgfortran"; + script = "sh ${test_source_directory}/has-gfortran.sh"; + script; + { + setup-ocamlc.byte-build-env; + script = "sh ${test_source_directory}/call-gfortran.sh ${cc} -c bigarrf.f"; + script; + all_modules = "bigarrf.o bigarrfstub.c bigarrfml.ml"; + ocamlc.byte; + output = "${test_build_directory}/program-output"; + stdout = "${output}"; + run; + check-program-output; + }{ + setup-ocamlopt.byte-build-env; + script = "sh ${test_source_directory}/call-gfortran.sh ${cc} -c bigarrf.f"; + script; + all_modules = "bigarrf.o bigarrfstub.c bigarrfml.ml"; + ocamlopt.byte; + output = "${test_build_directory}/program-output"; + stdout = "${output}"; + run; + check-program-output; + } *) open Bigarray diff --git a/testsuite/tests/lib-bigarray-file/mapfile.ml b/testsuite/tests/lib-bigarray-file/mapfile.ml index a359cd1bcc..f4008b7d8f 100644 --- a/testsuite/tests/lib-bigarray-file/mapfile.ml +++ b/testsuite/tests/lib-bigarray-file/mapfile.ml @@ -1,7 +1,7 @@ (* TEST - * hasunix - include unix - ** native + include unix; + hasunix; + native; *) open Bigarray diff --git a/testsuite/tests/lib-bigarray/bigarrays.ml b/testsuite/tests/lib-bigarray/bigarrays.ml index e43fc29518..7f055ce8cf 100644 --- a/testsuite/tests/lib-bigarray/bigarrays.ml +++ b/testsuite/tests/lib-bigarray/bigarrays.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) open Bigarray open Printf diff --git a/testsuite/tests/lib-bigarray/fftba.ml b/testsuite/tests/lib-bigarray/fftba.ml index a06ad1bc13..ee35acfcb7 100644 --- a/testsuite/tests/lib-bigarray/fftba.ml +++ b/testsuite/tests/lib-bigarray/fftba.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) open Bigarray diff --git a/testsuite/tests/lib-bigarray/pr5115.ml b/testsuite/tests/lib-bigarray/pr5115.ml index 74cbe51446..9b47d9a9c1 100644 --- a/testsuite/tests/lib-bigarray/pr5115.ml +++ b/testsuite/tests/lib-bigarray/pr5115.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) (* PR#5115 - multiple evaluation of bigarray expr *) diff --git a/testsuite/tests/lib-bigarray/weak_bigarray.ml b/testsuite/tests/lib-bigarray/weak_bigarray.ml index a0758120c9..76fdee9829 100644 --- a/testsuite/tests/lib-bigarray/weak_bigarray.ml +++ b/testsuite/tests/lib-bigarray/weak_bigarray.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) (** check that custom block are not copied by Weak.get_copy *) diff --git a/testsuite/tests/lib-bool/test.ml b/testsuite/tests/lib-bool/test.ml index e5a4bcf905..6a3c92bd16 100644 --- a/testsuite/tests/lib-bool/test.ml +++ b/testsuite/tests/lib-bool/test.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) let test_not () = assert (Bool.not false = true); diff --git a/testsuite/tests/lib-buffer/test.ml b/testsuite/tests/lib-buffer/test.ml index 7b1ab9a475..d1ba265be3 100644 --- a/testsuite/tests/lib-buffer/test.ml +++ b/testsuite/tests/lib-buffer/test.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) open Printf ;; diff --git a/testsuite/tests/lib-bytes-utf/test.ml b/testsuite/tests/lib-bytes-utf/test.ml index ac3483071f..7c5677b565 100644 --- a/testsuite/tests/lib-bytes-utf/test.ml +++ b/testsuite/tests/lib-bytes-utf/test.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) (* UTF codec tests *) diff --git a/testsuite/tests/lib-bytes/binary.ml b/testsuite/tests/lib-bytes/binary.ml index 899cdfe099..43ab4b4b8f 100644 --- a/testsuite/tests/lib-bytes/binary.ml +++ b/testsuite/tests/lib-bytes/binary.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) let err x = match Lazy.force x with diff --git a/testsuite/tests/lib-bytes/test_bytes.ml b/testsuite/tests/lib-bytes/test_bytes.ml index 1ea7281c7b..7349a07487 100644 --- a/testsuite/tests/lib-bytes/test_bytes.ml +++ b/testsuite/tests/lib-bytes/test_bytes.ml @@ -1,5 +1,5 @@ (* TEST - include testing + include testing; *) let test_raises_invalid_argument f x = diff --git a/testsuite/tests/lib-channels/input_all.ml b/testsuite/tests/lib-channels/input_all.ml index 711eed7369..1fe6e4b345 100644 --- a/testsuite/tests/lib-channels/input_all.ml +++ b/testsuite/tests/lib-channels/input_all.ml @@ -1,11 +1,12 @@ (* TEST - -* hassysthreads -include systhreads -readonly_files = "input_all.ml" -** bytecode -** native - + include systhreads; + readonly_files = "input_all.ml"; + hassysthreads; + { + bytecode; + }{ + native; + } *) let data_file = diff --git a/testsuite/tests/lib-channels/input_lines.ml b/testsuite/tests/lib-channels/input_lines.ml index 2c377ee06c..c293278526 100644 --- a/testsuite/tests/lib-channels/input_lines.ml +++ b/testsuite/tests/lib-channels/input_lines.ml @@ -1,6 +1,4 @@ -(* TEST - -*) +(* TEST *) open Printf diff --git a/testsuite/tests/lib-channels/refcounting.ml b/testsuite/tests/lib-channels/refcounting.ml index bc0b8dfe66..ec37425739 100644 --- a/testsuite/tests/lib-channels/refcounting.ml +++ b/testsuite/tests/lib-channels/refcounting.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* Test the behavior of channel refcounting. *) diff --git a/testsuite/tests/lib-digest/md5.ml b/testsuite/tests/lib-digest/md5.ml index d66ba52257..3d234c7f2f 100644 --- a/testsuite/tests/lib-digest/md5.ml +++ b/testsuite/tests/lib-digest/md5.ml @@ -1,5 +1,5 @@ (* TEST - flags += " -w -a " + flags += " -w -a "; *) (* Test int32 arithmetic and optimizations using the MD5 algorithm *) diff --git a/testsuite/tests/lib-dynlink-bytecode/main.ml b/testsuite/tests/lib-dynlink-bytecode/main.ml index dfeaa5dde9..d8070a4aa8 100644 --- a/testsuite/tests/lib-dynlink-bytecode/main.ml +++ b/testsuite/tests/lib-dynlink-bytecode/main.ml @@ -1,58 +1,53 @@ (* TEST - -include dynlink - -ld_library_path += "${test_build_directory}" - -readonly_files = "plug1.ml plug2.ml registry.ml stub1.c stub2.c" - -* shared-libraries -** setup-ocamlc.byte-build-env -*** ocamlc.byte -compile_only = "true" -all_modules = "registry.ml stub1.c stub2.c plug1.ml plug2.ml main.ml" -**** ocamlmklib -program = "plug1" -modules = "stub1.${objext}" -***** ocamlmklib -program = "plug2" -modules = "stub2.${objext}" -****** ocamlmklib -program = "plug1" -modules = "plug1.cmo" -******* ocamlmklib -program = "plug2" -modules = "plug2.cmo" - -compile_only = "false" - -******** ocamlc.byte -program = "${test_build_directory}/main.exe" -all_modules = "registry.cmo main.cmo" -********* run -arguments = "plug1.cma plug2.cma" -output = "main.output" -********** check-program-output - -******** ocamlc.byte -program = "${test_build_directory}/static.exe" -flags = "-linkall" -all_modules = "registry.cmo plug1.cma plug2.cma" -********* run -output = "static.output" -********** check-program-output -reference = "${test_source_directory}/static.reference" - -******** ocamlc.byte -program = "${test_build_directory}/custom.exe" -flags = "-custom -linkall -I ." -all_modules = "registry.cmo plug2.cma plug1.cma" -use_runtime = "false" -********* run -output = "custom.output" -********** check-program-output -reference = "${test_source_directory}/custom.reference" - + include dynlink; + ld_library_path += "${test_build_directory}"; + readonly_files = "plug1.ml plug2.ml registry.ml stub1.c stub2.c"; + shared-libraries; + setup-ocamlc.byte-build-env; + compile_only = "true"; + all_modules = "registry.ml stub1.c stub2.c plug1.ml plug2.ml main.ml"; + ocamlc.byte; + program = "plug1"; + modules = "stub1.${objext}"; + ocamlmklib; + program = "plug2"; + modules = "stub2.${objext}"; + ocamlmklib; + program = "plug1"; + modules = "plug1.cmo"; + ocamlmklib; + program = "plug2"; + modules = "plug2.cmo"; + compile_only = "false"; + ocamlmklib; + { + program = "${test_build_directory}/main.exe"; + all_modules = "registry.cmo main.cmo"; + ocamlc.byte; + arguments = "plug1.cma plug2.cma"; + output = "main.output"; + run; + check-program-output; + }{ + program = "${test_build_directory}/static.exe"; + flags = "-linkall"; + all_modules = "registry.cmo plug1.cma plug2.cma"; + ocamlc.byte; + output = "static.output"; + run; + reference = "${test_source_directory}/static.reference"; + check-program-output; + }{ + program = "${test_build_directory}/custom.exe"; + flags = "-custom -linkall -I ."; + all_modules = "registry.cmo plug2.cma plug1.cma"; + use_runtime = "false"; + ocamlc.byte; + output = "custom.output"; + run; + reference = "${test_source_directory}/custom.reference"; + check-program-output; + } *) let f x = print_string "This is Main.f\n"; x diff --git a/testsuite/tests/lib-dynlink-csharp/main.ml b/testsuite/tests/lib-dynlink-csharp/main.ml index 54798b7578..d6ac12b91e 100644 --- a/testsuite/tests/lib-dynlink-csharp/main.ml +++ b/testsuite/tests/lib-dynlink-csharp/main.ml @@ -1,83 +1,80 @@ (* TEST - -include dynlink - -readonly_files = "entry.c main.cs plugin.ml" - -* csharp-compiler -** shared-libraries -set csharp_cmd = "${csc} ${csc_flags} /out:main.exe main.cs" - -*** setup-ocamlc.byte-build-env -**** ocamlc.byte -module = "plugin.ml" -***** ocamlc.byte -module = "" -flags = "-output-obj" -program = "main.dll" -all_modules = "dynlink.cma main.ml entry.c" -****** script -script = "${csharp_cmd}" -******* run -program = "./main.exe" -******** check-program-output -reference = "${test_source_directory}/main.bytecode.reference" - -*** setup-ocamlc.byte-build-env -compiler_directory_suffix = "-dll" -**** ocamlc.byte -module = "plugin.ml" -***** ocamlc.byte -module = "" -flags = "-output-obj" -program = "main_obj.${objext}" -all_modules = "dynlink.cma entry.c main.ml" -****** script -script = "${mkdll} -maindll -o main.dll main_obj.${objext} entry.${objext} \ - ${ocamlsrcdir}/runtime/libcamlrun.${libext} ${bytecc_libs}" -******* script -script = "${csharp_cmd}" -******** run -program = "./main.exe" -********* check-program-output -reference = "${test_source_directory}/main.bytecode.reference" - -*** setup-ocamlopt.byte-build-env -**** ocamlopt.byte -program = "plugin.cmxs" -flags = "-shared" -all_modules = "plugin.ml" -***** ocamlopt.byte -flags = "-output-obj" -program= "main.dll" -all_modules = "dynlink.cmxa entry.c main.ml" -****** script -script = "${csharp_cmd}" -******* run -program = "./main.exe" -******** check-program-output -reference = "${test_source_directory}/main.native.reference" - -*** setup-ocamlopt.byte-build-env -compiler_directory_suffix = "-dll" -**** ocamlopt.byte -program = "plugin.cmxs" -flags = "-shared" -all_modules = "plugin.ml" -***** ocamlopt.byte -flags = "-output-obj" -program = "main_obj.${objext}" -all_modules = "dynlink.cmxa entry.c main.ml" -****** script -script = "${mkdll} -maindll -o main.dll main_obj.${objext} entry.${objext} \ - ${ocamlsrcdir}/runtime/libasmrun.${libext} ${nativecc_libs}" -******* script -script = "${csharp_cmd}" -******** run -program = "./main.exe" -********* check-program-output -reference = "${test_source_directory}/main.native.reference" - + include dynlink; + readonly_files = "entry.c main.cs plugin.ml"; + csharp-compiler; + set csharp_cmd = "${csc} ${csc_flags} /out:main.exe main.cs"; + shared-libraries; + { + setup-ocamlc.byte-build-env; + module = "plugin.ml"; + ocamlc.byte; + module = ""; + flags = "-output-obj"; + program = "main.dll"; + all_modules = "dynlink.cma main.ml entry.c"; + ocamlc.byte; + script = "${csharp_cmd}"; + script; + program = "./main.exe"; + run; + reference = "${test_source_directory}/main.bytecode.reference"; + check-program-output; + }{ + compiler_directory_suffix = "-dll"; + setup-ocamlc.byte-build-env; + module = "plugin.ml"; + ocamlc.byte; + module = ""; + flags = "-output-obj"; + program = "main_obj.${objext}"; + all_modules = "dynlink.cma entry.c main.ml"; + ocamlc.byte; + script = "${mkdll} -maindll -o main.dll main_obj.${objext} entry.${objext} \ + ${ocamlsrcdir}/runtime/libcamlrun.${libext} ${bytecc_libs}"; + script; + script = "${csharp_cmd}"; + script; + program = "./main.exe"; + run; + reference = "${test_source_directory}/main.bytecode.reference"; + check-program-output; + }{ + setup-ocamlopt.byte-build-env; + program = "plugin.cmxs"; + flags = "-shared"; + all_modules = "plugin.ml"; + ocamlopt.byte; + flags = "-output-obj"; + program = "main.dll"; + all_modules = "dynlink.cmxa entry.c main.ml"; + ocamlopt.byte; + script = "${csharp_cmd}"; + script; + program = "./main.exe"; + run; + reference = "${test_source_directory}/main.native.reference"; + check-program-output; + }{ + compiler_directory_suffix = "-dll"; + setup-ocamlopt.byte-build-env; + program = "plugin.cmxs"; + flags = "-shared"; + all_modules = "plugin.ml"; + ocamlopt.byte; + flags = "-output-obj"; + program = "main_obj.${objext}"; + all_modules = "dynlink.cmxa entry.c main.ml"; + ocamlopt.byte; + script = "${mkdll} -maindll -o main.dll main_obj.${objext} entry.${objext} \ + ${ocamlsrcdir}/runtime/libasmrun.${libext} ${nativecc_libs}"; + script; + script = "${csharp_cmd}"; + script; + program = "./main.exe"; + run; + reference = "${test_source_directory}/main.native.reference"; + check-program-output; + } *) let load s = diff --git a/testsuite/tests/lib-dynlink-domains/main.ml b/testsuite/tests/lib-dynlink-domains/main.ml index d87ddc24e4..a1393cc184 100644 --- a/testsuite/tests/lib-dynlink-domains/main.ml +++ b/testsuite/tests/lib-dynlink-domains/main.ml @@ -1,172 +1,172 @@ (* TEST - -include dynlink -libraries = "" -readonly_files = "store.ml main.ml Plugin_0.ml Plugin_0_0.ml Plugin_0_0_0.ml Plugin_0_0_0_0.ml Plugin_0_0_0_1.ml Plugin_0_0_0_2.ml Plugin_1.ml Plugin_1_0.ml Plugin_1_0_0.ml Plugin_1_0_0_0.ml Plugin_1_1.ml Plugin_1_2.ml Plugin_1_2_0.ml Plugin_1_2_0_0.ml Plugin_1_2_1.ml Plugin_1_2_2.ml Plugin_1_2_2_0.ml Plugin_1_2_3.ml Plugin_1_2_3_0.ml" - -*01 not-windows -*02 shared-libraries -*03 setup-ocamlc.byte-build-env -*04 ocamlc.byte -module = "store.ml" -*05 ocamlc.byte -module = "Plugin_0.ml" -*06 ocamlc.byte -module = "Plugin_0_0.ml" -*07 ocamlc.byte -module = "Plugin_0_0_0.ml" -*08 ocamlc.byte -module = "Plugin_0_0_0_0.ml" -*09 ocamlc.byte -module = "Plugin_0_0_0_1.ml" -*10 ocamlc.byte -module = "Plugin_0_0_0_2.ml" -*11 ocamlc.byte -module = "Plugin_1.ml" -*12 ocamlc.byte -module = "Plugin_1_0.ml" -*13 ocamlc.byte -module = "Plugin_1_0_0.ml" -*14 ocamlc.byte -module = "Plugin_1_0_0_0.ml" -*15 ocamlc.byte -module = "Plugin_1_1.ml" -*16 ocamlc.byte -module = "Plugin_1_2.ml" -*17 ocamlc.byte -module = "Plugin_1_2_0.ml" -*18 ocamlc.byte -module = "Plugin_1_2_0_0.ml" -*19 ocamlc.byte -module = "Plugin_1_2_1.ml" -*20 ocamlc.byte -module = "Plugin_1_2_2.ml" -*21 ocamlc.byte -module = "Plugin_1_2_2_0.ml" -*22 ocamlc.byte -module = "Plugin_1_2_3.ml" -*23 ocamlc.byte -module = "Plugin_1_2_3_0.ml" -*24 ocamlc.byte -module = "main.ml" -*25 ocamlc.byte -program = "./main.byte.exe" -libraries= "dynlink" -all_modules = "store.cmo main.cmo" -module = "" -*26 run -*27 check-program-output - -*02 native-dynlink -*03 setup-ocamlopt.byte-build-env -*04 ocamlopt.byte -flags = "" -module = "store.ml" -*05 ocamlopt.byte -flags = "-shared" -program= "Plugin_0.cmxs" -module = "" -all_modules = "Plugin_0.ml" -*06 ocamlopt.byte -flags = "-shared" -program= "Plugin_0_0.cmxs" -module = "" -all_modules = "Plugin_0_0.ml" -*07 ocamlopt.byte -flags = "-shared" -program= "Plugin_0_0_0.cmxs" -module = "" -all_modules = "Plugin_0_0_0.ml" -*08 ocamlopt.byte -flags = "-shared" -program= "Plugin_0_0_0_0.cmxs" -module = "" -all_modules = "Plugin_0_0_0_0.ml" -*09 ocamlopt.byte -flags = "-shared" -program= "Plugin_0_0_0_1.cmxs" -module = "" -all_modules = "Plugin_0_0_0_1.ml" -*10 ocamlopt.byte -flags = "-shared" -program= "Plugin_0_0_0_2.cmxs" -module = "" -all_modules = "Plugin_0_0_0_2.ml" -*11 ocamlopt.byte -flags = "-shared" -program= "Plugin_1.cmxs" -module = "" -all_modules = "Plugin_1.ml" -*12 ocamlopt.byte -flags = "-shared" -program= "Plugin_1_0.cmxs" -module = "" -all_modules = "Plugin_1_0.ml" -*13 ocamlopt.byte -flags = "-shared" -program= "Plugin_1_0_0.cmxs" -module = "" -all_modules = "Plugin_1_0_0.ml" -*14 ocamlopt.byte -flags = "-shared" -program= "Plugin_1_0_0_0.cmxs" -module = "" -all_modules = "Plugin_1_0_0_0.ml" -*15 ocamlopt.byte -flags = "-shared" -program= "Plugin_1_1.cmxs" -module = "" -all_modules = "Plugin_1_1.ml" -*16 ocamlopt.byte -flags = "-shared" -program= "Plugin_1_2.cmxs" -module = "" -all_modules = "Plugin_1_2.ml" -*17 ocamlopt.byte -flags = "-shared" -program= "Plugin_1_2_0.cmxs" -module = "" -all_modules = "Plugin_1_2_0.ml" -*18 ocamlopt.byte -flags = "-shared" -program= "Plugin_1_2_0_0.cmxs" -module = "" -all_modules = "Plugin_1_2_0_0.ml" -*19 ocamlopt.byte -flags = "-shared" -program= "Plugin_1_2_1.cmxs" -module = "" -all_modules = "Plugin_1_2_1.ml" -*20 ocamlopt.byte -flags = "-shared" -program= "Plugin_1_2_2.cmxs" -module = "" -all_modules = "Plugin_1_2_2.ml" -*21 ocamlopt.byte -flags = "-shared" -program= "Plugin_1_2_2_0.cmxs" -module = "" -all_modules = "Plugin_1_2_2_0.ml" -*22 ocamlopt.byte -flags = "-shared" -program= "Plugin_1_2_3.cmxs" -module = "" -all_modules = "Plugin_1_2_3.ml" -*23 ocamlopt.byte -flags = "-shared" -program= "Plugin_1_2_3_0.cmxs" -module = "" -all_modules = "Plugin_1_2_3_0.ml" -*24 ocamlopt.byte -flags = "" -module = "main.ml" -*25 ocamlopt.byte -program = "./main.exe" -libraries="dynlink" -all_modules = "store.cmx main.cmx" -module = "" -*26 run -*27 check-program-output + include dynlink; + libraries = ""; + readonly_files = "store.ml main.ml Plugin_0.ml Plugin_0_0.ml Plugin_0_0_0.ml Plugin_0_0_0_0.ml Plugin_0_0_0_1.ml Plugin_0_0_0_2.ml Plugin_1.ml Plugin_1_0.ml Plugin_1_0_0.ml Plugin_1_0_0_0.ml Plugin_1_1.ml Plugin_1_2.ml Plugin_1_2_0.ml Plugin_1_2_0_0.ml Plugin_1_2_1.ml Plugin_1_2_2.ml Plugin_1_2_2_0.ml Plugin_1_2_3.ml Plugin_1_2_3_0.ml"; + not-windows; + { + shared-libraries; + setup-ocamlc.byte-build-env; + module = "store.ml"; + ocamlc.byte; + module = "Plugin_0.ml"; + ocamlc.byte; + module = "Plugin_0_0.ml"; + ocamlc.byte; + module = "Plugin_0_0_0.ml"; + ocamlc.byte; + module = "Plugin_0_0_0_0.ml"; + ocamlc.byte; + module = "Plugin_0_0_0_1.ml"; + ocamlc.byte; + module = "Plugin_0_0_0_2.ml"; + ocamlc.byte; + module = "Plugin_1.ml"; + ocamlc.byte; + module = "Plugin_1_0.ml"; + ocamlc.byte; + module = "Plugin_1_0_0.ml"; + ocamlc.byte; + module = "Plugin_1_0_0_0.ml"; + ocamlc.byte; + module = "Plugin_1_1.ml"; + ocamlc.byte; + module = "Plugin_1_2.ml"; + ocamlc.byte; + module = "Plugin_1_2_0.ml"; + ocamlc.byte; + module = "Plugin_1_2_0_0.ml"; + ocamlc.byte; + module = "Plugin_1_2_1.ml"; + ocamlc.byte; + module = "Plugin_1_2_2.ml"; + ocamlc.byte; + module = "Plugin_1_2_2_0.ml"; + ocamlc.byte; + module = "Plugin_1_2_3.ml"; + ocamlc.byte; + module = "Plugin_1_2_3_0.ml"; + ocamlc.byte; + module = "main.ml"; + ocamlc.byte; + program = "./main.byte.exe"; + libraries = "dynlink"; + all_modules = "store.cmo main.cmo"; + module = ""; + ocamlc.byte; + run; + check-program-output; + }{ + native-dynlink; + setup-ocamlopt.byte-build-env; + flags = ""; + module = "store.ml"; + ocamlopt.byte; + flags = "-shared"; + program = "Plugin_0.cmxs"; + module = ""; + all_modules = "Plugin_0.ml"; + ocamlopt.byte; + flags = "-shared"; + program = "Plugin_0_0.cmxs"; + module = ""; + all_modules = "Plugin_0_0.ml"; + ocamlopt.byte; + flags = "-shared"; + program = "Plugin_0_0_0.cmxs"; + module = ""; + all_modules = "Plugin_0_0_0.ml"; + ocamlopt.byte; + flags = "-shared"; + program = "Plugin_0_0_0_0.cmxs"; + module = ""; + all_modules = "Plugin_0_0_0_0.ml"; + ocamlopt.byte; + flags = "-shared"; + program = "Plugin_0_0_0_1.cmxs"; + module = ""; + all_modules = "Plugin_0_0_0_1.ml"; + ocamlopt.byte; + flags = "-shared"; + program = "Plugin_0_0_0_2.cmxs"; + module = ""; + all_modules = "Plugin_0_0_0_2.ml"; + ocamlopt.byte; + flags = "-shared"; + program = "Plugin_1.cmxs"; + module = ""; + all_modules = "Plugin_1.ml"; + ocamlopt.byte; + flags = "-shared"; + program = "Plugin_1_0.cmxs"; + module = ""; + all_modules = "Plugin_1_0.ml"; + ocamlopt.byte; + flags = "-shared"; + program = "Plugin_1_0_0.cmxs"; + module = ""; + all_modules = "Plugin_1_0_0.ml"; + ocamlopt.byte; + flags = "-shared"; + program = "Plugin_1_0_0_0.cmxs"; + module = ""; + all_modules = "Plugin_1_0_0_0.ml"; + ocamlopt.byte; + flags = "-shared"; + program = "Plugin_1_1.cmxs"; + module = ""; + all_modules = "Plugin_1_1.ml"; + ocamlopt.byte; + flags = "-shared"; + program = "Plugin_1_2.cmxs"; + module = ""; + all_modules = "Plugin_1_2.ml"; + ocamlopt.byte; + flags = "-shared"; + program = "Plugin_1_2_0.cmxs"; + module = ""; + all_modules = "Plugin_1_2_0.ml"; + ocamlopt.byte; + flags = "-shared"; + program = "Plugin_1_2_0_0.cmxs"; + module = ""; + all_modules = "Plugin_1_2_0_0.ml"; + ocamlopt.byte; + flags = "-shared"; + program = "Plugin_1_2_1.cmxs"; + module = ""; + all_modules = "Plugin_1_2_1.ml"; + ocamlopt.byte; + flags = "-shared"; + program = "Plugin_1_2_2.cmxs"; + module = ""; + all_modules = "Plugin_1_2_2.ml"; + ocamlopt.byte; + flags = "-shared"; + program = "Plugin_1_2_2_0.cmxs"; + module = ""; + all_modules = "Plugin_1_2_2_0.ml"; + ocamlopt.byte; + flags = "-shared"; + program = "Plugin_1_2_3.cmxs"; + module = ""; + all_modules = "Plugin_1_2_3.ml"; + ocamlopt.byte; + flags = "-shared"; + program = "Plugin_1_2_3_0.cmxs"; + module = ""; + all_modules = "Plugin_1_2_3_0.ml"; + ocamlopt.byte; + flags = ""; + module = "main.ml"; + ocamlopt.byte; + program = "./main.exe"; + libraries = "dynlink"; + all_modules = "store.cmx main.cmx"; + module = ""; + ocamlopt.byte; + run; + check-program-output; + } *) (* This module and all plugin modules are generated by a call to test_generator.ml with parameters: diff --git a/testsuite/tests/lib-dynlink-init-info/test.ml b/testsuite/tests/lib-dynlink-init-info/test.ml index c6105dd752..21aa3973fa 100644 --- a/testsuite/tests/lib-dynlink-init-info/test.ml +++ b/testsuite/tests/lib-dynlink-init-info/test.ml @@ -1,5 +1,5 @@ (* TEST - include dynlink + include dynlink; *) (* Make sure dynlink state info is accurate before any load diff --git a/testsuite/tests/lib-dynlink-initializers/test10_main.ml b/testsuite/tests/lib-dynlink-initializers/test10_main.ml index 2ed0a22a8d..8305cd1c35 100644 --- a/testsuite/tests/lib-dynlink-initializers/test10_main.ml +++ b/testsuite/tests/lib-dynlink-initializers/test10_main.ml @@ -1,42 +1,42 @@ -(* TEST +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -include dynlink - -readonly_files = "test10_plugin.ml" -flags += "-g" - -libraries = "" - -* no-flambda -** shared-libraries -*** setup-ocamlc.byte-build-env -**** ocamlc.byte -module = "test10_main.ml" -**** ocamlc.byte -module = "test10_plugin.ml" -**** ocamlc.byte -program = "${test_build_directory}/test10.byte" -libraries = "dynlink" -all_modules = "test10_main.cmo" -***** run -****** check-program-output -reference = "${test_source_directory}/test10_main.byte.reference" - -*** native-dynlink -**** setup-ocamlopt.byte-build-env -***** ocamlopt.byte -module = "test10_main.ml" -***** ocamlopt.byte -program = "test10_plugin.cmxs" -flags = "-shared" -all_modules = "test10_plugin.ml" -***** ocamlopt.byte -program = "${test_build_directory}/test10.exe" -libraries = "dynlink" -all_modules = "test10_main.cmx" -****** run -******* check-program-output -reference = "${test_source_directory}/test10_main.native.reference" *) (* Check that a module in the main program whose initializer has not @@ -55,3 +55,50 @@ let () = | Dynlink.Error (Dynlink.Library's_module_initializers_failed exn) -> Printf.eprintf "Error: %s\n%!" (Printexc.to_string exn); Printexc.print_backtrace stderr + +(* TEST + include dynlink; + readonly_files = "test10_plugin.ml"; + flags += "-g"; + libraries = ""; + no-flambda; + shared-libraries; + { + setup-ocamlc.byte-build-env; + { + module = "test10_main.ml"; + ocamlc.byte; + }{ + module = "test10_plugin.ml"; + ocamlc.byte; + }{ + program = "${test_build_directory}/test10.byte"; + libraries = "dynlink"; + all_modules = "test10_main.cmo"; + ocamlc.byte; + run; + reference = "${test_source_directory}/test10_main.byte.reference"; + check-program-output; + } + }{ + native-dynlink; + setup-ocamlopt.byte-build-env; + { + module = "test10_main.ml"; + ocamlopt.byte; + }{ + program = "test10_plugin.cmxs"; + flags = "-shared"; + all_modules = "test10_plugin.ml"; + ocamlopt.byte; + }{ + program = "${test_build_directory}/test10.exe"; + libraries = "dynlink"; + all_modules = "test10_main.cmx"; + ocamlopt.byte; + run; + reference = "${test_source_directory}/test10_main.native.reference"; + check-program-output; + } + } +*) diff --git a/testsuite/tests/lib-dynlink-initializers/test1_main.ml b/testsuite/tests/lib-dynlink-initializers/test1_main.ml index 34d3b5ae18..0958573147 100644 --- a/testsuite/tests/lib-dynlink-initializers/test1_main.ml +++ b/testsuite/tests/lib-dynlink-initializers/test1_main.ml @@ -1,40 +1,48 @@ (* TEST - -include dynlink - -readonly_files = "test1_inited_second.ml test1_plugin.ml" - -libraries = "" - -* shared-libraries -** setup-ocamlc.byte-build-env -*** ocamlc.byte -module = "test1_main.ml" -*** ocamlc.byte -module = "test1_inited_second.ml" -*** ocamlc.byte -module = "test1_plugin.ml" -*** ocamlc.byte -program = "${test_build_directory}/test1.byte" -libraries = "dynlink" -all_modules = "test1_main.cmo test1_inited_second.cmo" -**** run - -** native-dynlink -*** setup-ocamlopt.byte-build-env -**** ocamlopt.byte -module = "test1_main.ml" -**** ocamlopt.byte -module = "test1_inited_second.ml" -**** ocamlopt.byte -program = "test1_plugin.cmxs" -flags = "-shared" -all_modules = "test1_plugin.ml" -**** ocamlopt.byte -program = "${test_build_directory}/test1.exe" -libraries = "dynlink" -all_modules = "test1_main.cmx test1_inited_second.cmx" -***** run + include dynlink; + readonly_files = "test1_inited_second.ml test1_plugin.ml"; + libraries = ""; + shared-libraries; + { + setup-ocamlc.byte-build-env; + { + module = "test1_main.ml"; + ocamlc.byte; + }{ + module = "test1_inited_second.ml"; + ocamlc.byte; + }{ + module = "test1_plugin.ml"; + ocamlc.byte; + }{ + program = "${test_build_directory}/test1.byte"; + libraries = "dynlink"; + all_modules = "test1_main.cmo test1_inited_second.cmo"; + ocamlc.byte; + run; + } + }{ + native-dynlink; + setup-ocamlopt.byte-build-env; + { + module = "test1_main.ml"; + ocamlopt.byte; + }{ + module = "test1_inited_second.ml"; + ocamlopt.byte; + }{ + program = "test1_plugin.cmxs"; + flags = "-shared"; + all_modules = "test1_plugin.ml"; + ocamlopt.byte; + }{ + program = "${test_build_directory}/test1.exe"; + libraries = "dynlink"; + all_modules = "test1_main.cmx test1_inited_second.cmx"; + ocamlopt.byte; + run; + } + } *) (* Check that a module in the main program whose initializer has not diff --git a/testsuite/tests/lib-dynlink-initializers/test2_main.ml b/testsuite/tests/lib-dynlink-initializers/test2_main.ml index 6ec8921f09..e1507e7dff 100644 --- a/testsuite/tests/lib-dynlink-initializers/test2_main.ml +++ b/testsuite/tests/lib-dynlink-initializers/test2_main.ml @@ -1,40 +1,48 @@ (* TEST - -include dynlink - -readonly_files = "test2_inited_first.ml test2_plugin.ml" - -libraries = "" - -* shared-libraries -** setup-ocamlc.byte-build-env -*** ocamlc.byte -module = "test2_inited_first.ml" -*** ocamlc.byte -module = "test2_main.ml" -*** ocamlc.byte -module = "test2_plugin.ml" -*** ocamlc.byte -program = "${test_build_directory}/test2.byte" -libraries = "dynlink" -all_modules = "test2_inited_first.cmo test2_main.cmo" -**** run - -** native-dynlink -*** setup-ocamlopt.byte-build-env -**** ocamlopt.byte -module = "test2_inited_first.ml" -**** ocamlopt.byte -module = "test2_main.ml" -**** ocamlopt.byte -program = "test2_plugin.cmxs" -flags = "-shared" -all_modules = "test2_plugin.ml" -**** ocamlopt.byte -program = "${test_build_directory}/test2.exe" -libraries = "dynlink" -all_modules = "test2_inited_first.cmx test2_main.cmx" -***** run + include dynlink; + readonly_files = "test2_inited_first.ml test2_plugin.ml"; + libraries = ""; + shared-libraries; + { + setup-ocamlc.byte-build-env; + { + module = "test2_inited_first.ml"; + ocamlc.byte; + }{ + module = "test2_main.ml"; + ocamlc.byte; + }{ + module = "test2_plugin.ml"; + ocamlc.byte; + }{ + program = "${test_build_directory}/test2.byte"; + libraries = "dynlink"; + all_modules = "test2_inited_first.cmo test2_main.cmo"; + ocamlc.byte; + run; + } + }{ + native-dynlink; + setup-ocamlopt.byte-build-env; + { + module = "test2_inited_first.ml"; + ocamlopt.byte; + }{ + module = "test2_main.ml"; + ocamlopt.byte; + }{ + program = "test2_plugin.cmxs"; + flags = "-shared"; + all_modules = "test2_plugin.ml"; + ocamlopt.byte; + }{ + program = "${test_build_directory}/test2.exe"; + libraries = "dynlink"; + all_modules = "test2_inited_first.cmx test2_main.cmx"; + ocamlopt.byte; + run; + } + } *) (* Check that a shared library can refer to a module in the main program diff --git a/testsuite/tests/lib-dynlink-initializers/test3_main.ml b/testsuite/tests/lib-dynlink-initializers/test3_main.ml index 8f0b94009b..b2f3e44743 100644 --- a/testsuite/tests/lib-dynlink-initializers/test3_main.ml +++ b/testsuite/tests/lib-dynlink-initializers/test3_main.ml @@ -1,46 +1,56 @@ (* TEST - -include dynlink - -readonly_files = "test3_plugin_a.ml test3_plugin_b.ml" - -libraries = "" - -* shared-libraries -** setup-ocamlc.byte-build-env -*** ocamlc.byte -module = "test3_main.ml" -*** ocamlc.byte -module = "test3_plugin_a.ml" -*** ocamlc.byte -module = "test3_plugin_b.ml" -*** ocamlc.byte -program = "test3_plugin.cma" -flags = "-a" -all_modules = "test3_plugin_a.cmo test3_plugin_b.cmo" -*** ocamlc.byte -program = "${test_build_directory}/test3.byte" -libraries = "dynlink" -all_modules = "test3_main.cmo" -**** run - -** native-dynlink -*** setup-ocamlopt.byte-build-env -**** ocamlopt.byte -module = "test3_main.ml" -**** ocamlopt.byte -module = "test3_plugin_a.ml" -**** ocamlopt.byte -module = "test3_plugin_b.ml" -**** ocamlopt.byte -program = "test3_plugin.cmxs" -flags = "-shared" -all_modules = "test3_plugin_a.cmx test3_plugin_b.cmx" -**** ocamlopt.byte -program = "${test_build_directory}/test3.exe" -libraries = "dynlink" -all_modules = "test3_main.cmx" -***** run + include dynlink; + readonly_files = "test3_plugin_a.ml test3_plugin_b.ml"; + libraries = ""; + shared-libraries; + { + setup-ocamlc.byte-build-env; + { + module = "test3_main.ml"; + ocamlc.byte; + }{ + module = "test3_plugin_a.ml"; + ocamlc.byte; + }{ + module = "test3_plugin_b.ml"; + ocamlc.byte; + }{ + program = "test3_plugin.cma"; + flags = "-a"; + all_modules = "test3_plugin_a.cmo test3_plugin_b.cmo"; + ocamlc.byte; + }{ + program = "${test_build_directory}/test3.byte"; + libraries = "dynlink"; + all_modules = "test3_main.cmo"; + ocamlc.byte; + run; + } + }{ + native-dynlink; + setup-ocamlopt.byte-build-env; + { + module = "test3_main.ml"; + ocamlopt.byte; + }{ + module = "test3_plugin_a.ml"; + ocamlopt.byte; + }{ + module = "test3_plugin_b.ml"; + ocamlopt.byte; + }{ + program = "test3_plugin.cmxs"; + flags = "-shared"; + all_modules = "test3_plugin_a.cmx test3_plugin_b.cmx"; + ocamlopt.byte; + }{ + program = "${test_build_directory}/test3.exe"; + libraries = "dynlink"; + all_modules = "test3_main.cmx"; + ocamlopt.byte; + run; + } + } *) (* Check that one module in a shared library can refer to another module diff --git a/testsuite/tests/lib-dynlink-initializers/test4_main.ml b/testsuite/tests/lib-dynlink-initializers/test4_main.ml index e9cd79ee8e..d24880e073 100644 --- a/testsuite/tests/lib-dynlink-initializers/test4_main.ml +++ b/testsuite/tests/lib-dynlink-initializers/test4_main.ml @@ -1,46 +1,56 @@ (* TEST - -include dynlink - -readonly_files = "test4_plugin_a.ml test4_plugin_b.ml" - -libraries = "" - -* shared-libraries -** setup-ocamlc.byte-build-env -*** ocamlc.byte -module = "test4_main.ml" -*** ocamlc.byte -module = "test4_plugin_b.ml" -*** ocamlc.byte -module = "test4_plugin_a.ml" -*** ocamlc.byte -program = "test4_plugin.cma" -flags = "-a" -all_modules = "test4_plugin_a.cmo test4_plugin_b.cmo" -*** ocamlc.byte -program = "${test_build_directory}/test4.byte" -libraries = "dynlink" -all_modules = "test4_main.cmo" -**** run - -** native-dynlink -*** setup-ocamlopt.byte-build-env -**** ocamlopt.byte -module = "test4_main.ml" -**** ocamlopt.byte -module = "test4_plugin_b.ml" -**** ocamlopt.byte -module = "test4_plugin_a.ml" -**** ocamlopt.byte -program = "test4_plugin.cmxs" -flags = "-shared" -all_modules = "test4_plugin_a.cmx test4_plugin_b.cmx" -**** ocamlopt.byte -program = "${test_build_directory}/test4.exe" -libraries = "dynlink" -all_modules = "test4_main.cmx" -***** run + include dynlink; + readonly_files = "test4_plugin_a.ml test4_plugin_b.ml"; + libraries = ""; + shared-libraries; + { + setup-ocamlc.byte-build-env; + { + module = "test4_main.ml"; + ocamlc.byte; + }{ + module = "test4_plugin_b.ml"; + ocamlc.byte; + }{ + module = "test4_plugin_a.ml"; + ocamlc.byte; + }{ + program = "test4_plugin.cma"; + flags = "-a"; + all_modules = "test4_plugin_a.cmo test4_plugin_b.cmo"; + ocamlc.byte; + }{ + program = "${test_build_directory}/test4.byte"; + libraries = "dynlink"; + all_modules = "test4_main.cmo"; + ocamlc.byte; + run; + } + }{ + native-dynlink; + setup-ocamlopt.byte-build-env; + { + module = "test4_main.ml"; + ocamlopt.byte; + }{ + module = "test4_plugin_b.ml"; + ocamlopt.byte; + }{ + module = "test4_plugin_a.ml"; + ocamlopt.byte; + }{ + program = "test4_plugin.cmxs"; + flags = "-shared"; + all_modules = "test4_plugin_a.cmx test4_plugin_b.cmx"; + ocamlopt.byte; + }{ + program = "${test_build_directory}/test4.exe"; + libraries = "dynlink"; + all_modules = "test4_main.cmx"; + ocamlopt.byte; + run; + } + } *) (* Check that a module in a shared library cannot refer to another diff --git a/testsuite/tests/lib-dynlink-initializers/test5_main.ml b/testsuite/tests/lib-dynlink-initializers/test5_main.ml index 0f39f63a42..3c9aab13ce 100644 --- a/testsuite/tests/lib-dynlink-initializers/test5_main.ml +++ b/testsuite/tests/lib-dynlink-initializers/test5_main.ml @@ -1,52 +1,64 @@ (* TEST - -include dynlink - -readonly_files = "test5_plugin_a.ml test5_plugin_b.ml test5_second_plugin.ml" - -libraries = "" - -* shared-libraries -** setup-ocamlc.byte-build-env -*** ocamlc.byte -module = "test5_main.ml" -*** ocamlc.byte -module = "test5_plugin_a.ml" -*** ocamlc.byte -module = "test5_plugin_b.ml" -*** ocamlc.byte -module = "test5_second_plugin.ml" -*** ocamlc.byte -program = "test5_plugin.cma" -flags = "-a" -all_modules = "test5_plugin_a.cmo test5_plugin_b.cmo" -*** ocamlc.byte -program = "${test_build_directory}/test5.byte" -libraries = "dynlink" -all_modules = "test5_main.cmo" -**** run - -** native-dynlink -*** setup-ocamlopt.byte-build-env -**** ocamlopt.byte -module = "test5_main.ml" -**** ocamlopt.byte -module = "test5_plugin_a.ml" -**** ocamlopt.byte -module = "test5_plugin_b.ml" -**** ocamlopt.byte -program = "test5_plugin.cmxs" -flags = "-shared" -all_modules = "test5_plugin_a.cmx test5_plugin_b.cmx" -**** ocamlopt.byte -program = "test5_second_plugin.cmxs" -flags = "-shared" -all_modules = "test5_second_plugin.ml" -**** ocamlopt.byte -program = "${test_build_directory}/test5.exe" -libraries = "dynlink" -all_modules = "test5_main.cmx" -***** run + include dynlink; + readonly_files = "test5_plugin_a.ml test5_plugin_b.ml test5_second_plugin.ml"; + libraries = ""; + shared-libraries; + { + setup-ocamlc.byte-build-env; + { + module = "test5_main.ml"; + ocamlc.byte; + }{ + module = "test5_plugin_a.ml"; + ocamlc.byte; + }{ + module = "test5_plugin_b.ml"; + ocamlc.byte; + }{ + module = "test5_second_plugin.ml"; + ocamlc.byte; + }{ + program = "test5_plugin.cma"; + flags = "-a"; + all_modules = "test5_plugin_a.cmo test5_plugin_b.cmo"; + ocamlc.byte; + }{ + program = "${test_build_directory}/test5.byte"; + libraries = "dynlink"; + all_modules = "test5_main.cmo"; + ocamlc.byte; + run; + } + }{ + native-dynlink; + setup-ocamlopt.byte-build-env; + { + module = "test5_main.ml"; + ocamlopt.byte; + }{ + module = "test5_plugin_a.ml"; + ocamlopt.byte; + }{ + module = "test5_plugin_b.ml"; + ocamlopt.byte; + }{ + program = "test5_plugin.cmxs"; + flags = "-shared"; + all_modules = "test5_plugin_a.cmx test5_plugin_b.cmx"; + ocamlopt.byte; + }{ + program = "test5_second_plugin.cmxs"; + flags = "-shared"; + all_modules = "test5_second_plugin.ml"; + ocamlopt.byte; + }{ + program = "${test_build_directory}/test5.exe"; + libraries = "dynlink"; + all_modules = "test5_main.cmx"; + ocamlopt.byte; + run; + } + } *) (* Check that when one shared library loads another shared library then diff --git a/testsuite/tests/lib-dynlink-initializers/test6_main.ml b/testsuite/tests/lib-dynlink-initializers/test6_main.ml index 332b594c08..3828bdaa4a 100644 --- a/testsuite/tests/lib-dynlink-initializers/test6_main.ml +++ b/testsuite/tests/lib-dynlink-initializers/test6_main.ml @@ -1,42 +1,50 @@ (* TEST - -include dynlink - -readonly_files = "test6_plugin.ml test6_second_plugin.ml" - -libraries = "" - -* shared-libraries -** setup-ocamlc.byte-build-env -*** ocamlc.byte -module = "test6_main.ml" -*** ocamlc.byte -module = "test6_plugin.ml" -*** ocamlc.byte -module = "test6_second_plugin.ml" -*** ocamlc.byte -program = "${test_build_directory}/test6.byte" -libraries = "dynlink" -all_modules = "test6_main.cmo" -**** run - -** native-dynlink -*** setup-ocamlopt.byte-build-env -**** ocamlopt.byte -module = "test6_main.ml" -**** ocamlopt.byte -program = "test6_plugin.cmxs" -flags = "-shared" -all_modules = "test6_plugin.ml" -**** ocamlopt.byte -program = "test6_second_plugin.cmxs" -flags = "-shared" -all_modules = "test6_second_plugin.ml" -**** ocamlopt.byte -program = "${test_build_directory}/test6.exe" -libraries = "dynlink" -all_modules = "test6_main.cmx" -***** run + include dynlink; + readonly_files = "test6_plugin.ml test6_second_plugin.ml"; + libraries = ""; + shared-libraries; + { + setup-ocamlc.byte-build-env; + { + module = "test6_main.ml"; + ocamlc.byte; + }{ + module = "test6_plugin.ml"; + ocamlc.byte; + }{ + module = "test6_second_plugin.ml"; + ocamlc.byte; + }{ + program = "${test_build_directory}/test6.byte"; + libraries = "dynlink"; + all_modules = "test6_main.cmo"; + ocamlc.byte; + run; + } + }{ + native-dynlink; + setup-ocamlopt.byte-build-env; + { + module = "test6_main.ml"; + ocamlopt.byte; + }{ + program = "test6_plugin.cmxs"; + flags = "-shared"; + all_modules = "test6_plugin.ml"; + ocamlopt.byte; + }{ + program = "test6_second_plugin.cmxs"; + flags = "-shared"; + all_modules = "test6_second_plugin.ml"; + ocamlopt.byte; + }{ + program = "${test_build_directory}/test6.exe"; + libraries = "dynlink"; + all_modules = "test6_main.cmx"; + ocamlopt.byte; + run; + } + } *) (* Check that a module in a loaded shared library whose initializer has not diff --git a/testsuite/tests/lib-dynlink-initializers/test7_main.ml b/testsuite/tests/lib-dynlink-initializers/test7_main.ml index f3dba0c566..6e3bbbc522 100644 --- a/testsuite/tests/lib-dynlink-initializers/test7_main.ml +++ b/testsuite/tests/lib-dynlink-initializers/test7_main.ml @@ -1,40 +1,48 @@ (* TEST - -include dynlink - -readonly_files = "test7_interface_only.mli test7_plugin.ml" - -libraries = "" - -* shared-libraries -** setup-ocamlc.byte-build-env -*** ocamlc.byte -module = "test7_interface_only.mli" -*** ocamlc.byte -module = "test7_main.ml" -*** ocamlc.byte -module = "test7_plugin.ml" -*** ocamlc.byte -program = "${test_build_directory}/test7.byte" -libraries = "dynlink" -all_modules = "test7_main.cmo" -**** run - -** native-dynlink -*** setup-ocamlopt.byte-build-env -**** ocamlopt.byte -module = "test7_interface_only.mli" -**** ocamlopt.byte -module = "test7_main.ml" -**** ocamlopt.byte -program = "test7_plugin.cmxs" -flags = "-shared" -all_modules = "test7_plugin.ml" -**** ocamlopt.byte -program = "${test_build_directory}/test7.exe" -libraries = "dynlink" -all_modules = "test7_main.cmx" -***** run + include dynlink; + readonly_files = "test7_interface_only.mli test7_plugin.ml"; + libraries = ""; + shared-libraries; + { + setup-ocamlc.byte-build-env; + { + module = "test7_interface_only.mli"; + ocamlc.byte; + }{ + module = "test7_main.ml"; + ocamlc.byte; + }{ + module = "test7_plugin.ml"; + ocamlc.byte; + }{ + program = "${test_build_directory}/test7.byte"; + libraries = "dynlink"; + all_modules = "test7_main.cmo"; + ocamlc.byte; + run; + } + }{ + native-dynlink; + setup-ocamlopt.byte-build-env; + { + module = "test7_interface_only.mli"; + ocamlopt.byte; + }{ + module = "test7_main.ml"; + ocamlopt.byte; + }{ + program = "test7_plugin.cmxs"; + flags = "-shared"; + all_modules = "test7_plugin.ml"; + ocamlopt.byte; + }{ + program = "${test_build_directory}/test7.exe"; + libraries = "dynlink"; + all_modules = "test7_main.cmx"; + ocamlopt.byte; + run; + } + } *) (* Check that a shared library can depend on an interface-only module diff --git a/testsuite/tests/lib-dynlink-initializers/test8_main.ml b/testsuite/tests/lib-dynlink-initializers/test8_main.ml index 45bba9602c..0f194afcb8 100644 --- a/testsuite/tests/lib-dynlink-initializers/test8_main.ml +++ b/testsuite/tests/lib-dynlink-initializers/test8_main.ml @@ -1,50 +1,62 @@ (* TEST - -include dynlink - -readonly_files = "test8_plugin_a.ml test8_plugin_b.ml test8_plugin_b.mli" - -libraries = "" - -* shared-libraries -** setup-ocamlc.byte-build-env -*** ocamlc.byte -module = "test8_main.ml" -*** ocamlc.byte -module = "test8_plugin_b.mli" -*** ocamlc.byte -module = "test8_plugin_a.ml" -*** ocamlc.byte -module = "test8_plugin_b.ml" -*** ocamlc.byte -program = "test8_plugin.cma" -flags = "-a" -all_modules = "test8_plugin_a.cmo test8_plugin_b.cmo" -*** ocamlc.byte -program = "${test_build_directory}/test8.byte" -libraries = "dynlink" -all_modules = "test8_main.cmo" -**** run - -** native-dynlink -*** setup-ocamlopt.byte-build-env -**** ocamlopt.byte -module = "test8_main.ml" -**** ocamlopt.byte -module = "test8_plugin_b.mli" -**** ocamlopt.byte -module = "test8_plugin_a.ml" -**** ocamlopt.byte -module = "test8_plugin_b.ml" -**** ocamlopt.byte -program = "test8_plugin.cmxs" -flags = "-shared" -all_modules = "test8_plugin_a.cmx test8_plugin_b.cmx" -**** ocamlopt.byte -program = "${test_build_directory}/test8.exe" -libraries = "dynlink" -all_modules = "test8_main.cmx" -***** run + include dynlink; + readonly_files = "test8_plugin_a.ml test8_plugin_b.ml test8_plugin_b.mli"; + libraries = ""; + shared-libraries; + { + setup-ocamlc.byte-build-env; + { + module = "test8_main.ml"; + ocamlc.byte; + }{ + module = "test8_plugin_b.mli"; + ocamlc.byte; + }{ + module = "test8_plugin_a.ml"; + ocamlc.byte; + }{ + module = "test8_plugin_b.ml"; + ocamlc.byte; + }{ + program = "test8_plugin.cma"; + flags = "-a"; + all_modules = "test8_plugin_a.cmo test8_plugin_b.cmo"; + ocamlc.byte; + }{ + program = "${test_build_directory}/test8.byte"; + libraries = "dynlink"; + all_modules = "test8_main.cmo"; + ocamlc.byte; + run; + } + }{ + native-dynlink; + setup-ocamlopt.byte-build-env; + { + module = "test8_main.ml"; + ocamlopt.byte; + }{ + module = "test8_plugin_b.mli"; + ocamlopt.byte; + }{ + module = "test8_plugin_a.ml"; + ocamlopt.byte; + }{ + module = "test8_plugin_b.ml"; + ocamlopt.byte; + }{ + program = "test8_plugin.cmxs"; + flags = "-shared"; + all_modules = "test8_plugin_a.cmx test8_plugin_b.cmx"; + ocamlopt.byte; + }{ + program = "${test_build_directory}/test8.exe"; + libraries = "dynlink"; + all_modules = "test8_main.cmx"; + ocamlopt.byte; + run; + } + } *) (* Check that modules of a shared library can have interface-only diff --git a/testsuite/tests/lib-dynlink-initializers/test9_main.ml b/testsuite/tests/lib-dynlink-initializers/test9_main.ml index f74ddccb8a..fcb1128633 100644 --- a/testsuite/tests/lib-dynlink-initializers/test9_main.ml +++ b/testsuite/tests/lib-dynlink-initializers/test9_main.ml @@ -1,46 +1,56 @@ (* TEST - -include dynlink - -readonly_files = "test9_plugin.ml test9_second_plugin.ml test9_second_plugin.mli" - -libraries = "" - -* shared-libraries -** setup-ocamlc.byte-build-env -*** ocamlc.byte -module = "test9_second_plugin.mli" -*** ocamlc.byte -module = "test9_main.ml" -*** ocamlc.byte -module = "test9_plugin.ml" -*** ocamlc.byte -module = "test9_second_plugin.ml" -*** ocamlc.byte -program = "${test_build_directory}/test9.byte" -libraries = "dynlink" -all_modules = "test9_main.cmo" -**** run - -** native-dynlink -*** setup-ocamlopt.byte-build-env -**** ocamlopt.byte -module = "test9_second_plugin.mli" -**** ocamlopt.byte -module = "test9_main.ml" -**** ocamlopt.byte -program = "test9_plugin.cmxs" -flags = "-shared" -all_modules = "test9_plugin.ml" -**** ocamlopt.byte -program = "test9_second_plugin.cmxs" -flags = "-shared" -all_modules = "test9_second_plugin.ml" -**** ocamlopt.byte -program = "${test_build_directory}/test9.exe" -libraries = "dynlink" -all_modules = "test9_main.cmx" -***** run + include dynlink; + readonly_files = "test9_plugin.ml test9_second_plugin.ml test9_second_plugin.mli"; + libraries = ""; + shared-libraries; + { + setup-ocamlc.byte-build-env; + { + module = "test9_second_plugin.mli"; + ocamlc.byte; + }{ + module = "test9_main.ml"; + ocamlc.byte; + }{ + module = "test9_plugin.ml"; + ocamlc.byte; + }{ + module = "test9_second_plugin.ml"; + ocamlc.byte; + }{ + program = "${test_build_directory}/test9.byte"; + libraries = "dynlink"; + all_modules = "test9_main.cmo"; + ocamlc.byte; + run; + } + }{ + native-dynlink; + setup-ocamlopt.byte-build-env; + { + module = "test9_second_plugin.mli"; + ocamlopt.byte; + }{ + module = "test9_main.ml"; + ocamlopt.byte; + }{ + program = "test9_plugin.cmxs"; + flags = "-shared"; + all_modules = "test9_plugin.ml"; + ocamlopt.byte; + }{ + program = "test9_second_plugin.cmxs"; + flags = "-shared"; + all_modules = "test9_second_plugin.ml"; + ocamlopt.byte; + }{ + program = "${test_build_directory}/test9.exe"; + libraries = "dynlink"; + all_modules = "test9_main.cmx"; + ocamlopt.byte; + run; + } + } *) (* Check that a shared library can depend on an interface-only module diff --git a/testsuite/tests/lib-dynlink-native/main.ml b/testsuite/tests/lib-dynlink-native/main.ml index 284ebbd101..ab64368e54 100644 --- a/testsuite/tests/lib-dynlink-native/main.ml +++ b/testsuite/tests/lib-dynlink-native/main.ml @@ -1,202 +1,204 @@ (* TEST + readonly_files = "a.ml api.ml b.ml bug.ml c.ml factorial.c pack_client.ml \ + packed1_client.ml packed1.ml plugin2.ml plugin4.ml plugin_ext.ml \ + plugin_high_arity.ml plugin.ml plugin.mli plugin_ref.ml plugin_simple.ml \ + plugin_thread.ml"; + subdirectories = "sub"; + include systhreads; + include dynlink; + hassysthreads; + libraries = ""; (* We will add them manually where appropriated *) + native-dynlink; + ocamlopt_default_flags = "";(* Removes the -ccopt -no-pie on ised on OpenBSD *) + setup-ocamlopt.byte-build-env; + module = "api.ml"; + ocamlopt.byte; + flags = "-opaque"; + module = "plugin.mli"; + ocamlopt.byte; + flags = ""; + module = "plugin.ml"; + ocamlopt.byte; + module = ""; + flags = "-shared"; + program = "plugin.so"; + all_modules = "plugin.cmx"; + ocamlopt.byte; + script = "mv plugin.cmx plugin.cmx.bak"; + script; + flags = ""; + module = "plugin2.ml"; + ocamlopt.byte; + script = "mv plugin.cmx.bak plugin.cmx"; + script; + module = ""; + flags = "-shared"; + program = "plugin2.so"; + all_modules = "plugin2.cmx"; + ocamlopt.byte; + flags = ""; + module = "sub/plugin.ml"; + ocamlopt.byte; + module = ""; + flags = "-shared"; + program = "sub/plugin.so"; + all_modules = "sub/plugin.cmx"; + ocamlopt.byte; + cwd = "sub"; + cd; + module = "api.mli"; + flags = "-opaque"; + ocamlopt.byte; + flags = ""; + module = "api.ml"; + ocamlopt.byte; + script = "mv api.cmx api.cmx.bak"; + script; + module = "plugin3.ml"; + ocamlopt.byte; + script = "mv api.cmx.bak api.cmx"; + script; + cwd = ".."; + cd; + module = ""; + flags = "-shared"; + program = "sub/plugin3.so"; + all_modules = "sub/plugin3.cmx"; + ocamlopt.byte; + flags = ""; + module = "plugin4.ml"; + ocamlopt.byte; + module = ""; + flags = "-shared"; + program = "plugin4.so"; + all_modules = "plugin4.cmx"; + ocamlopt.byte; + module = "packed1.ml"; + flags = "-for-pack Mypack"; + ocamlopt.byte; + flags = "-S -pack"; + module = ""; + program = "mypack.cmx"; + all_modules = "packed1.cmx"; + ocamlopt.byte; + program = "mypack.so"; + flags = "-shared"; + all_modules = "mypack.cmx"; + ocamlopt.byte; + program = "packed1.so"; + flags = "-shared"; + all_modules = "packed1.cmx"; + ocamlopt.byte; + flags = ""; + module = "pack_client.ml"; + ocamlopt.byte; + module = ""; + program = "pack_client.so"; + flags = "-shared"; + all_modules = "pack_client.cmx"; + ocamlopt.byte; + flags = ""; + module = "plugin_ref.ml"; + ocamlopt.byte; + module = ""; + program = "plugin_ref.so"; + flags = "-shared"; + all_modules = "plugin_ref.cmx"; + ocamlopt.byte; + flags = ""; + module = "plugin_high_arity.ml"; + ocamlopt.byte; + module = ""; + program = "plugin_high_arity.so"; + flags = "-shared"; + all_modules = "plugin_high_arity.cmx"; + ocamlopt.byte; + flags = "-ccopt ${shared_library_cflags}"; + module = "factorial.c"; + ocamlopt.byte; + flags = ""; + module = "plugin_ext.ml"; + ocamlopt.byte; + module = ""; + program = "plugin_ext.so"; + flags = "-shared"; + all_modules = "factorial.${objext} plugin_ext.cmx"; + ocamlopt.byte; + module = "plugin_simple.ml"; + flags = ""; + ocamlopt.byte; + { + module = ""; + program = "plugin_simple.so"; + flags = "-shared"; + all_modules = "plugin_simple.cmx"; + ocamlopt.byte; + }{ + module = "bug.ml"; + flags = ""; + ocamlopt.byte; + { + module = ""; + program = "bug.so"; + flags = "-shared"; + all_modules = "bug.cmx"; + ocamlopt.byte; + }{ + module = "plugin_thread.ml"; + flags = ""; + ocamlopt.byte; + module = ""; + program = "plugin_thread.so"; + flags = "-shared"; + all_modules = "plugin_thread.cmx"; + ocamlopt.byte; + program = "plugin4_unix.so"; + all_modules = "unix.cmxa plugin4.cmx"; + ocamlopt.byte; + flags = ""; + compile_only = "true"; + all_modules = "a.ml b.ml c.ml main.ml"; + ocamlopt.byte; + module = ""; + compile_only = "false"; + flags = "-shared"; + program = "a.so"; + all_modules = "a.cmx"; + ocamlopt.byte; + program = "b.so"; + all_modules = "b.cmx"; + ocamlopt.byte; + program = "c.so"; + all_modules = "c.cmx"; + ocamlopt.byte; + program = "mylib.cmxa"; + flags = "-a"; + all_modules = "plugin.cmx plugin2.cmx"; + ocamlopt.byte; + program = "mylib.so"; + flags = "-shared -linkall"; + all_modules = "mylib.cmxa"; + ocamlopt.byte; + program = "${test_build_directory}/main.exe"; + libraries = "unix threads dynlink"; + flags = "-linkall"; + all_modules = "api.cmx main.cmx"; + ocamlopt.byte; + (* + On OpenBSD, the compiler produces warnings like + /usr/bin/ld: warning: creating a DT_TEXTREL in a shared object. + So the compiler output is not empty on OpenBSD so an emptiness check + would fail on this platform. -readonly_files = "a.ml api.ml b.ml bug.ml c.ml factorial.c pack_client.ml \ - packed1_client.ml packed1.ml plugin2.ml plugin4.ml plugin_ext.ml \ - plugin_high_arity.ml plugin.ml plugin.mli plugin_ref.ml \ - plugin_simple.ml plugin_thread.ml" -subdirectories = "sub" + We thus do not check compiler output. This was not done either before the + test was ported to ocamltest. + *) -* hassysthreads -include systhreads -include dynlink - -** native-dynlink -libraries = "" (* We will add them manually where appropriated *) -*** setup-ocamlopt.byte-build-env -ocamlopt_default_flags = "" (* Removes the -ccopt -no-pie on ised on OpenBSD *) - -**** ocamlopt.byte -module = "api.ml" -***** ocamlopt.byte -flags = "-opaque" -module = "plugin.mli" -****** ocamlopt.byte -flags = "" -module = "plugin.ml" -******* ocamlopt.byte -module= "" -flags = "-shared" -program = "plugin.so" -all_modules = "plugin.cmx" -******** script -script = "mv plugin.cmx plugin.cmx.bak" -********* ocamlopt.byte -flags = "" -module = "plugin2.ml" -********** script -script = "mv plugin.cmx.bak plugin.cmx" -*********** ocamlopt.byte -module= "" -flags = "-shared" -program = "plugin2.so" -all_modules = "plugin2.cmx" -************ ocamlopt.byte -flags = "" -module = "sub/plugin.ml" -************* ocamlopt.byte -module = "" -flags = "-shared" -program = "sub/plugin.so" -all_modules = "sub/plugin.cmx" -************** cd -cwd = "sub" -*************** ocamlopt.byte -module = "api.mli" -flags = "-opaque" -**************** ocamlopt.byte -flags = "" -module = "api.ml" -***************** script -script = "mv api.cmx api.cmx.bak" -****************** ocamlopt.byte -module = "plugin3.ml" -******************* script -script = "mv api.cmx.bak api.cmx" -******************** cd -cwd = ".." -********************* ocamlopt.byte -module = "" -flags = "-shared" -program = "sub/plugin3.so" -all_modules = "sub/plugin3.cmx" -********************** ocamlopt.byte -flags = "" -module = "plugin4.ml" -*********************** ocamlopt.byte -module = "" -flags = "-shared" -program = "plugin4.so" -all_modules = "plugin4.cmx" -************************ ocamlopt.byte -module = "packed1.ml" -flags = "-for-pack Mypack" -************************* ocamlopt.byte -flags = "-S -pack" -module = "" -program = "mypack.cmx" -all_modules = "packed1.cmx" -************************** ocamlopt.byte -program = "mypack.so" -flags = "-shared" -all_modules = "mypack.cmx" -*************************** ocamlopt.byte -program = "packed1.so" -flags = "-shared" -all_modules = "packed1.cmx" -**************************** ocamlopt.byte -flags = "" -module = "pack_client.ml" -***************************** ocamlopt.byte -module = "" -program = "pack_client.so" -flags = "-shared" -all_modules = "pack_client.cmx" -****************************** ocamlopt.byte -flags = "" -module = "plugin_ref.ml" -******************************* ocamlopt.byte -module = "" -program = "plugin_ref.so" -flags = "-shared" -all_modules = "plugin_ref.cmx" -******************************** ocamlopt.byte -flags = "" -module = "plugin_high_arity.ml" -********************************* ocamlopt.byte -module = "" -program = "plugin_high_arity.so" -flags = "-shared" -all_modules = "plugin_high_arity.cmx" -********************************** ocamlopt.byte -flags = "-ccopt ${shared_library_cflags}" -module = "factorial.c" -*********************************** ocamlopt.byte -flags = "" -module = "plugin_ext.ml" -************************************ ocamlopt.byte -module = "" -program = "plugin_ext.so" -flags = "-shared" -all_modules = "factorial.${objext} plugin_ext.cmx" -************************************* ocamlopt.byte -module = "plugin_simple.ml" -flags = "" -************************************** ocamlopt.byte -module = "" -program = "plugin_simple.so" -flags = "-shared" -all_modules = "plugin_simple.cmx" -************************************** ocamlopt.byte -module = "bug.ml" -flags = "" -*************************************** ocamlopt.byte -module = "" -program = "bug.so" -flags = "-shared" -all_modules = "bug.cmx" -*************************************** ocamlopt.byte -module = "plugin_thread.ml" -flags = "" -**************************************** ocamlopt.byte -module = "" -program = "plugin_thread.so" -flags = "-shared" -all_modules = "plugin_thread.cmx" -***************************************** ocamlopt.byte -program = "plugin4_unix.so" -all_modules = "unix.cmxa plugin4.cmx" -****************************************** ocamlopt.byte -flags = "" -compile_only = "true" -all_modules = "a.ml b.ml c.ml main.ml" -******************************************* ocamlopt.byte -module = "" -compile_only = "false" -flags = "-shared" -program = "a.so" -all_modules = "a.cmx" -******************************************** ocamlopt.byte -program = "b.so" -all_modules = "b.cmx" -********************************************* ocamlopt.byte -program = "c.so" -all_modules = "c.cmx" -********************************************** ocamlopt.byte -program = "mylib.cmxa" -flags = "-a" -all_modules = "plugin.cmx plugin2.cmx" -*********************************************** ocamlopt.byte -program = "mylib.so" -flags = "-shared -linkall" -all_modules = "mylib.cmxa" -************************************************ ocamlopt.byte -program = "${test_build_directory}/main.exe" -libraries = "unix threads dynlink" -flags = "-linkall" -all_modules = "api.cmx main.cmx" -(* -On OpenBSD, the compiler produces warnings like -/usr/bin/ld: warning: creating a DT_TEXTREL in a shared object. -So the compiler output is not empty on OpenBSD so an emptiness check -would fail on this platform. - -We thus do not check compiler output. This was not done either before the -test was ported to ocamltest. -*) - -************************************************* run -arguments = "plugin.so plugin2.so plugin_thread.so" -************************************************** check-program-output + arguments = "plugin.so plugin2.so plugin_thread.so"; + run; + check-program-output; + } + } *) let () = diff --git a/testsuite/tests/lib-dynlink-packed/loader.ml b/testsuite/tests/lib-dynlink-packed/loader.ml index ce617bc0d3..19add8903c 100644 --- a/testsuite/tests/lib-dynlink-packed/loader.ml +++ b/testsuite/tests/lib-dynlink-packed/loader.ml @@ -1,60 +1,71 @@ (* TEST - -include dynlink -libraries = "" -readonly_files = "a.ml b.ml loader.ml" - -* shared-libraries -** setup-ocamlc.byte-build-env -*** ocamlc.byte -flags = "-for-pack Packed" -module = "a.ml" -*** ocamlc.byte -flags = "-for-pack Packed" -module = "b.ml" -*** ocamlc.byte -program = "packed.cmo" -flags = "-pack" -all_modules = "a.cmo b.cmo" -*** ocamlc.byte -program = "${test_build_directory}/loader.byte" -flags = "-linkall" -include ocamlcommon -libraries += "dynlink" -all_modules = "loader.ml" -**** run -arguments = "packed.cmo" -exit_status = "0" -***** check-program-output -reference = "${test_source_directory}/byte.reference" - -** native-dynlink -*** setup-ocamlopt.byte-build-env -**** ocamlopt.byte -flags = "-for-pack Packed" -module = "a.ml" -**** ocamlopt.byte -flags = "-for-pack Packed" -module = "b.ml" -**** ocamlopt.byte -program = "packed.cmx" -flags = "-pack" -all_modules = "a.cmx b.cmx" -**** ocamlopt.byte -program = "plugin.cmxs" -flags = "-shared" -all_modules = "packed.cmx" -**** ocamlopt.byte -program = "${test_build_directory}/loader.exe" -flags = "-linkall" -include ocamlcommon -libraries += "dynlink" -all_modules = "loader.ml" -***** run -arguments = "plugin.cmxs" -exit_status = "0" -****** check-program-output -reference = "${test_source_directory}/native.reference" + include dynlink; + libraries = ""; + readonly_files = "a.ml b.ml loader.ml"; + shared-libraries; + { + setup-ocamlc.byte-build-env; + { + flags = "-for-pack Packed"; + module = "a.ml"; + ocamlc.byte; + }{ + flags = "-for-pack Packed"; + module = "b.ml"; + ocamlc.byte; + }{ + program = "packed.cmo"; + flags = "-pack"; + all_modules = "a.cmo b.cmo"; + ocamlc.byte; + }{ + program = "${test_build_directory}/loader.byte"; + flags = "-linkall"; + include ocamlcommon; + libraries += "dynlink"; + all_modules = "loader.ml"; + ocamlc.byte; + arguments = "packed.cmo"; + exit_status = "0"; + run; + reference = "${test_source_directory}/byte.reference"; + check-program-output; + } + }{ + native-dynlink; + setup-ocamlopt.byte-build-env; + { + flags = "-for-pack Packed"; + module = "a.ml"; + ocamlopt.byte; + }{ + flags = "-for-pack Packed"; + module = "b.ml"; + ocamlopt.byte; + }{ + program = "packed.cmx"; + flags = "-pack"; + all_modules = "a.cmx b.cmx"; + ocamlopt.byte; + }{ + program = "plugin.cmxs"; + flags = "-shared"; + all_modules = "packed.cmx"; + ocamlopt.byte; + }{ + program = "${test_build_directory}/loader.exe"; + flags = "-linkall"; + include ocamlcommon; + libraries += "dynlink"; + all_modules = "loader.ml"; + ocamlopt.byte; + arguments = "plugin.cmxs"; + exit_status = "0"; + run; + reference = "${test_source_directory}/native.reference"; + check-program-output; + } + } *) let () = try diff --git a/testsuite/tests/lib-dynlink-pr4229/main.ml b/testsuite/tests/lib-dynlink-pr4229/main.ml index 3cdc8937d3..a6ac99de6b 100644 --- a/testsuite/tests/lib-dynlink-pr4229/main.ml +++ b/testsuite/tests/lib-dynlink-pr4229/main.ml @@ -1,77 +1,77 @@ (* TEST - -include dynlink - -readonly_files = "abstract.mli abstract.ml static.ml client.ml main.ml" - -subdirectories = "sub" - -libraries = "" - -* shared-libraries -** setup-ocamlc.byte-build-env -*** cd -cwd = "sub" -**** ocamlc.byte -module = "abstract.mli" -***** ocamlc.byte -module = "abstract.ml" -****** cd -cwd = ".." -******* ocamlc.byte -module = "abstract.mli" -******** ocamlc.byte -module = "abstract.ml" -********* ocamlc.byte -module = "static.ml" -********** ocamlc.byte -module = "client.ml" -*********** ocamlc.byte -module = "main.ml" -************ ocamlc.byte -program = "${test_build_directory}/main" -libraries = "dynlink" -module = "" -all_modules = "abstract.cmo static.cmo main.cmo" -************* run -exit_status = "2" -************** check-program-output - -** native-dynlink -*** setup-ocamlopt.byte-build-env -**** cd -cwd = "sub" -***** ocamlopt.byte -module = "abstract.mli" -****** ocamlopt.byte -program = "abstract.cmxs" -flags = "-shared" -module = "" -all_modules = "abstract.ml" -******* cd -cwd = ".." -******** ocamlopt.byte -flags = "" -module = "abstract.mli" -********* ocamlopt.byte -module = "abstract.ml" -********** ocamlopt.byte -module = "static.ml" -*********** ocamlopt.byte -program = "client.cmxs" -flags = "-shared" -module = "" -all_modules = "client.ml" -*********** ocamlopt.byte -module = "main.ml" -************ ocamlopt.byte -program = "${test_build_directory}/main_native" -libraries = "dynlink" -module = "" -all_modules = "abstract.cmx static.cmx main.cmx" -************* run -exit_status = "2" -************** check-program-output + include dynlink; + readonly_files = "abstract.mli abstract.ml static.ml client.ml main.ml"; + subdirectories = "sub"; + libraries = ""; + shared-libraries; + { + setup-ocamlc.byte-build-env; + cwd = "sub"; + cd; + module = "abstract.mli"; + ocamlc.byte; + module = "abstract.ml"; + ocamlc.byte; + cwd = ".."; + cd; + module = "abstract.mli"; + ocamlc.byte; + module = "abstract.ml"; + ocamlc.byte; + module = "static.ml"; + ocamlc.byte; + module = "client.ml"; + ocamlc.byte; + module = "main.ml"; + ocamlc.byte; + program = "${test_build_directory}/main"; + libraries = "dynlink"; + module = ""; + all_modules = "abstract.cmo static.cmo main.cmo"; + ocamlc.byte; + exit_status = "2"; + run; + check-program-output; + }{ + native-dynlink; + setup-ocamlopt.byte-build-env; + cwd = "sub"; + cd; + module = "abstract.mli"; + ocamlopt.byte; + program = "abstract.cmxs"; + flags = "-shared"; + module = ""; + all_modules = "abstract.ml"; + ocamlopt.byte; + cwd = ".."; + cd; + flags = ""; + module = "abstract.mli"; + ocamlopt.byte; + module = "abstract.ml"; + ocamlopt.byte; + module = "static.ml"; + ocamlopt.byte; + { + program = "client.cmxs"; + flags = "-shared"; + module = ""; + all_modules = "client.ml"; + ocamlopt.byte; + }{ + module = "main.ml"; + ocamlopt.byte; + program = "${test_build_directory}/main_native"; + libraries = "dynlink"; + module = ""; + all_modules = "abstract.cmx static.cmx main.cmx"; + ocamlopt.byte; + exit_status = "2"; + run; + check-program-output; + } + } *) (* PR#4229 *) diff --git a/testsuite/tests/lib-dynlink-pr4839/test.ml b/testsuite/tests/lib-dynlink-pr4839/test.ml index 8d217be901..3efc44d125 100644 --- a/testsuite/tests/lib-dynlink-pr4839/test.ml +++ b/testsuite/tests/lib-dynlink-pr4839/test.ml @@ -1,231 +1,297 @@ (* TEST - -include dynlink -libraries = "" -subdirectories = "host plugin1 plugin2 plugin3 plugin4" - -* shared-libraries -** setup-ocamlc.byte-build-env -*** cd -cwd = "plugin1" -*** ocamlc.byte -module = "api.mli" -*** ocamlc.byte -flags = "-for-pack Packed" -module = "api.ml" -*** ocamlc.byte -program = "packed.cmo" -flags = "-pack" -all_modules = "api.cmo" -*** ocamlc.byte -program = "plugin.cma" -flags = "-a" -all_modules = "plugin.ml" -*** cd -cwd = ".." - -*** cd -cwd = "plugin2" -*** ocamlc.byte -module = "api.mli" -*** ocamlc.byte -flags = "-for-pack Packed" -module = "api.ml" -*** ocamlc.byte -program = "packed.cmo" -flags = "-pack" -all_modules = "api.cmo" -*** ocamlc.byte -program = "plugin.cma" -flags = "-a" -all_modules = "plugin.ml" -*** cd -cwd = ".." - -*** cd -cwd = "plugin3" -*** ocamlc.byte -module = "api.mli" -*** ocamlc.byte -flags = "-for-pack Packed" -module = "api.ml" -*** ocamlc.byte -program = "packed.cmo" -flags = "-pack" -all_modules = "api.cmo" -*** ocamlc.byte -program = "plugin.cma" -flags = "-a" -all_modules = "packed.cmo plugin.ml" -*** cd -cwd = ".." - -*** cd -cwd = "plugin4" -*** ocamlc.byte -module = "api.mli" -*** ocamlc.byte -flags = "-for-pack Packed" -module = "api.ml" -*** ocamlc.byte -program = "packed.cmo" -flags = "-pack" -all_modules = "api.cmo" -*** ocamlc.byte -program = "plugin.cma" -flags = "-a" -all_modules = "packed.cmo plugin.ml" -*** cd -cwd = ".." - -*** cd -cwd = "host" -*** ocamlc.byte -module = "api.mli" -*** ocamlc.byte -flags = "-for-pack Packed" -module = "api.ml" -*** ocamlc.byte -program = "packed.cmo" -flags = "-pack" -all_modules = "api.cmo" -*** ocamlc.byte -program = "./host.byt" -libraries = "dynlink" -all_modules = "packed.cmo host.ml" -**** run -arguments = "../plugin1/plugin.cma" -output = "byte.plugin1.result" -***** check-program-output -reference = "${test_source_directory}/byte.plugin1.reference" -**** run -arguments = "../plugin2/plugin.cma" -output = "byte.plugin2.result" -***** check-program-output -reference = "${test_source_directory}/byte.plugin2.reference" -**** run -arguments = "../plugin3/plugin.cma" -output = "byte.plugin3.result" -***** check-program-output -reference = "${test_source_directory}/byte.plugin3.reference" -**** run -arguments = "../plugin4/plugin.cma" -output = "byte.plugin4.result" -***** check-program-output -reference = "${test_source_directory}/byte.plugin4.reference" -*** cd -cwd = ".." - -** native-dynlink -*** setup-ocamlopt.byte-build-env - -**** cd -cwd = "plugin1" -**** ocamlopt.byte -module = "api.mli" -**** ocamlopt.byte -flags = "-for-pack Packed" -module = "api.ml" -**** ocamlopt.byte -program = "packed.cmx" -flags = "-pack" -all_modules = "api.cmx" -**** ocamlopt.byte -program = "plugin.cmxs" -flags = "-shared" -all_modules = "plugin.ml" -**** cd -cwd = ".." - -**** cd -cwd = "plugin2" -**** ocamlopt.byte -module = "api.mli" -**** ocamlopt.byte -flags = "-for-pack Packed" -module = "api.ml" -**** ocamlopt.byte -program = "packed.cmx" -flags = "-pack" -all_modules = "api.cmx" -**** ocamlopt.byte -program = "plugin.cmxs" -flags = "-shared" -all_modules = "plugin.ml" -*** cd -cwd = ".." - -**** cd -cwd = "plugin3" -**** ocamlopt.byte -module = "api.mli" -**** ocamlopt.byte -flags = "-for-pack Packed" -module = "api.ml" -**** ocamlopt.byte -program = "packed.cmx" -flags = "-pack" -all_modules = "api.cmx" -**** ocamlopt.byte -program = "plugin.cmxs" -flags = "-shared" -all_modules = "packed.cmx plugin.ml" -**** cd -cwd = ".." - -**** cd -cwd = "plugin4" -**** ocamlopt.byte -module = "api.mli" -**** ocamlopt.byte -flags = "-for-pack Packed" -module = "api.ml" -**** ocamlopt.byte -program = "packed.cmx" -flags = "-pack" -all_modules = "api.cmx" -**** ocamlopt.byte -program = "plugin.cmxs" -flags = "-shared" -all_modules = "packed.cmx plugin.ml" -**** cd -cwd = ".." - -**** cd -cwd = "host" -**** ocamlopt.byte -module = "api.mli" -**** ocamlopt.byte -flags = "-for-pack Packed" -module = "api.ml" -**** ocamlopt.byte -program = "packed.cmx" -flags = "-pack" -all_modules = "api.cmx" -**** ocamlopt.byte -program = "./host.exe" -libraries = "dynlink" -all_modules = "packed.cmx host.ml" -***** run -arguments = "../plugin1/plugin.cmxs" -output = "native.plugin1.result" -****** check-program-output -reference = "${test_source_directory}/native.plugin1.reference" -***** run -arguments = "../plugin2/plugin.cmxs" -output = "native.plugin2.result" -****** check-program-output -reference = "${test_source_directory}/native.plugin2.reference" -***** run -arguments = "../plugin3/plugin.cmxs" -output = "native.plugin3.result" -****** check-program-output -reference = "${test_source_directory}/native.plugin3.reference" -***** run -arguments = "../plugin4/plugin.cmxs" -output = "native.plugin4.result" -****** check-program-output -reference = "${test_source_directory}/native.plugin4.reference" -**** cd -cwd = ".." + include dynlink; + libraries = ""; + subdirectories = "host plugin1 plugin2 plugin3 plugin4"; + shared-libraries; + { + setup-ocamlc.byte-build-env; + { + cwd = "plugin1"; + cd; + }{ + module = "api.mli"; + ocamlc.byte; + }{ + flags = "-for-pack Packed"; + module = "api.ml"; + ocamlc.byte; + }{ + program = "packed.cmo"; + flags = "-pack"; + all_modules = "api.cmo"; + ocamlc.byte; + }{ + program = "plugin.cma"; + flags = "-a"; + all_modules = "plugin.ml"; + ocamlc.byte; + }{ + cwd = ".."; + cd; + }{ + cwd = "plugin2"; + cd; + }{ + module = "api.mli"; + ocamlc.byte; + }{ + flags = "-for-pack Packed"; + module = "api.ml"; + ocamlc.byte; + }{ + program = "packed.cmo"; + flags = "-pack"; + all_modules = "api.cmo"; + ocamlc.byte; + }{ + program = "plugin.cma"; + flags = "-a"; + all_modules = "plugin.ml"; + ocamlc.byte; + }{ + cwd = ".."; + cd; + }{ + cwd = "plugin3"; + cd; + }{ + module = "api.mli"; + ocamlc.byte; + }{ + flags = "-for-pack Packed"; + module = "api.ml"; + ocamlc.byte; + }{ + program = "packed.cmo"; + flags = "-pack"; + all_modules = "api.cmo"; + ocamlc.byte; + }{ + program = "plugin.cma"; + flags = "-a"; + all_modules = "packed.cmo plugin.ml"; + ocamlc.byte; + }{ + cwd = ".."; + cd; + }{ + cwd = "plugin4"; + cd; + }{ + module = "api.mli"; + ocamlc.byte; + }{ + flags = "-for-pack Packed"; + module = "api.ml"; + ocamlc.byte; + }{ + program = "packed.cmo"; + flags = "-pack"; + all_modules = "api.cmo"; + ocamlc.byte; + }{ + program = "plugin.cma"; + flags = "-a"; + all_modules = "packed.cmo plugin.ml"; + ocamlc.byte; + }{ + cwd = ".."; + cd; + }{ + cwd = "host"; + cd; + }{ + module = "api.mli"; + ocamlc.byte; + }{ + flags = "-for-pack Packed"; + module = "api.ml"; + ocamlc.byte; + }{ + program = "packed.cmo"; + flags = "-pack"; + all_modules = "api.cmo"; + ocamlc.byte; + }{ + program = "./host.byt"; + libraries = "dynlink"; + all_modules = "packed.cmo host.ml"; + ocamlc.byte; + { + arguments = "../plugin1/plugin.cma"; + output = "byte.plugin1.result"; + run; + reference = "${test_source_directory}/byte.plugin1.reference"; + check-program-output; + }{ + arguments = "../plugin2/plugin.cma"; + output = "byte.plugin2.result"; + run; + reference = "${test_source_directory}/byte.plugin2.reference"; + check-program-output; + }{ + arguments = "../plugin3/plugin.cma"; + output = "byte.plugin3.result"; + run; + reference = "${test_source_directory}/byte.plugin3.reference"; + check-program-output; + }{ + arguments = "../plugin4/plugin.cma"; + output = "byte.plugin4.result"; + run; + reference = "${test_source_directory}/byte.plugin4.reference"; + check-program-output; + } + }{ + cwd = ".."; + cd; + } + }{ + native-dynlink; + { + setup-ocamlopt.byte-build-env; + { + cwd = "plugin1"; + cd; + }{ + module = "api.mli"; + ocamlopt.byte; + }{ + flags = "-for-pack Packed"; + module = "api.ml"; + ocamlopt.byte; + }{ + program = "packed.cmx"; + flags = "-pack"; + all_modules = "api.cmx"; + ocamlopt.byte; + }{ + program = "plugin.cmxs"; + flags = "-shared"; + all_modules = "plugin.ml"; + ocamlopt.byte; + }{ + cwd = ".."; + cd; + }{ + cwd = "plugin2"; + cd; + }{ + module = "api.mli"; + ocamlopt.byte; + }{ + flags = "-for-pack Packed"; + module = "api.ml"; + ocamlopt.byte; + }{ + program = "packed.cmx"; + flags = "-pack"; + all_modules = "api.cmx"; + ocamlopt.byte; + }{ + program = "plugin.cmxs"; + flags = "-shared"; + all_modules = "plugin.ml"; + ocamlopt.byte; + } + }{ + cwd = ".."; + cd; + { + cwd = "plugin3"; + cd; + }{ + module = "api.mli"; + ocamlopt.byte; + }{ + flags = "-for-pack Packed"; + module = "api.ml"; + ocamlopt.byte; + }{ + program = "packed.cmx"; + flags = "-pack"; + all_modules = "api.cmx"; + ocamlopt.byte; + }{ + program = "plugin.cmxs"; + flags = "-shared"; + all_modules = "packed.cmx plugin.ml"; + ocamlopt.byte; + }{ + cwd = ".."; + cd; + }{ + cwd = "plugin4"; + cd; + }{ + module = "api.mli"; + ocamlopt.byte; + }{ + flags = "-for-pack Packed"; + module = "api.ml"; + ocamlopt.byte; + }{ + program = "packed.cmx"; + flags = "-pack"; + all_modules = "api.cmx"; + ocamlopt.byte; + }{ + program = "plugin.cmxs"; + flags = "-shared"; + all_modules = "packed.cmx plugin.ml"; + ocamlopt.byte; + }{ + cwd = ".."; + cd; + }{ + cwd = "host"; + cd; + }{ + module = "api.mli"; + ocamlopt.byte; + }{ + flags = "-for-pack Packed"; + module = "api.ml"; + ocamlopt.byte; + }{ + program = "packed.cmx"; + flags = "-pack"; + all_modules = "api.cmx"; + ocamlopt.byte; + }{ + program = "./host.exe"; + libraries = "dynlink"; + all_modules = "packed.cmx host.ml"; + ocamlopt.byte; + { + arguments = "../plugin1/plugin.cmxs"; + output = "native.plugin1.result"; + run; + reference = "${test_source_directory}/native.plugin1.reference"; + check-program-output; + }{ + arguments = "../plugin2/plugin.cmxs"; + output = "native.plugin2.result"; + run; + reference = "${test_source_directory}/native.plugin2.reference"; + check-program-output; + }{ + arguments = "../plugin3/plugin.cmxs"; + output = "native.plugin3.result"; + run; + reference = "${test_source_directory}/native.plugin3.reference"; + check-program-output; + }{ + arguments = "../plugin4/plugin.cmxs"; + output = "native.plugin4.result"; + run; + reference = "${test_source_directory}/native.plugin4.reference"; + check-program-output; + } + }{ + cwd = ".."; + cd; + } + } + } *) diff --git a/testsuite/tests/lib-dynlink-pr6950/loader.ml b/testsuite/tests/lib-dynlink-pr6950/loader.ml index d676934d1d..f7ba5595af 100644 --- a/testsuite/tests/lib-dynlink-pr6950/loader.ml +++ b/testsuite/tests/lib-dynlink-pr6950/loader.ml @@ -1,44 +1,50 @@ (* TEST - -include dynlink -libraries = "" -readonly_files = "config.ml b.ml" - -* shared-libraries -** setup-ocamlc.byte-build-env -*** ocamlc.byte -program = "plugin.cma" -flags = "-a" -all_modules = "config.ml b.ml" -*** ocamlc.byte -program = "${test_build_directory}/loader.byte" -flags = "-linkall" -include ocamlcommon -libraries += "dynlink" -all_modules = "loader.ml" -**** run -arguments = "plugin.cma" -exit_status = "2" -***** check-program-output -reference = "${test_source_directory}/byte.reference" - -** native-dynlink -*** setup-ocamlopt.byte-build-env -**** ocamlopt.byte -program = "plugin.cmxs" -flags = "-shared" -all_modules = "config.ml b.ml" -**** ocamlopt.byte -program = "${test_build_directory}/loader.exe" -flags = "-linkall" -include ocamlcommon -libraries += "dynlink" -all_modules = "loader.ml" -***** run -arguments = "plugin.cmxs" -exit_status = "2" -****** check-program-output -reference = "${test_source_directory}/native.reference" + include dynlink; + libraries = ""; + readonly_files = "config.ml b.ml"; + shared-libraries; + { + setup-ocamlc.byte-build-env; + { + program = "plugin.cma"; + flags = "-a"; + all_modules = "config.ml b.ml"; + ocamlc.byte; + }{ + program = "${test_build_directory}/loader.byte"; + flags = "-linkall"; + include ocamlcommon; + libraries += "dynlink"; + all_modules = "loader.ml"; + ocamlc.byte; + arguments = "plugin.cma"; + exit_status = "2"; + run; + reference = "${test_source_directory}/byte.reference"; + check-program-output; + } + }{ + native-dynlink; + setup-ocamlopt.byte-build-env; + { + program = "plugin.cmxs"; + flags = "-shared"; + all_modules = "config.ml b.ml"; + ocamlopt.byte; + }{ + program = "${test_build_directory}/loader.exe"; + flags = "-linkall"; + include ocamlcommon; + libraries += "dynlink"; + all_modules = "loader.ml"; + ocamlopt.byte; + arguments = "plugin.cmxs"; + exit_status = "2"; + run; + reference = "${test_source_directory}/native.reference"; + check-program-output; + } + } *) let () = try diff --git a/testsuite/tests/lib-dynlink-pr9209/dyn.ml b/testsuite/tests/lib-dynlink-pr9209/dyn.ml index 051e7afc39..1a56bc8f64 100644 --- a/testsuite/tests/lib-dynlink-pr9209/dyn.ml +++ b/testsuite/tests/lib-dynlink-pr9209/dyn.ml @@ -1,61 +1,61 @@ (* TEST - -include dynlink -readonly_files = "lib.ml lib2.ml test.c" -ld_library_path += "${test_build_directory}" - -* shared-libraries -** setup-ocamlc.byte-build-env -*** ocamlc.byte -compile_only = "true" -all_modules = "lib.ml lib2.ml test.c dyn.ml" -**** ocamlmklib -program = "lib" -modules = "lib.cmo test.${objext}" -compile_only = "false" -***** ocamlc.byte -program = "lib2.cma" -libraries = "" -all_modules = "lib2.cmo" -compile_only = "false" -flags = "-a" -****** ocamlc.byte -libraries += "dynlink" -program = "${test_build_directory}/main.exe" -all_modules = "dyn.cmo" -flags = "" -******* run -output = "main.output" -******** check-program-output - -** native-dynlink -*** setup-ocamlopt.byte-build-env -**** ocamlopt.byte -compile_only = "true" -all_modules = "lib.ml lib2.ml test.c dyn.ml" -***** ocamlmklib -program = "test" -modules = "test.${objext}" -compile_only = "false" -****** ocamlopt.byte -program = "lib.cmxs" -libraries = "" -flags = "-shared -cclib -L. -cclib -ltest" -all_modules = "lib.cmx" -compile_only = "false" -******* ocamlopt.byte -program = "lib2.cmxs" -all_modules = "lib2.cmx" -compile_only = "false" -flags = "-shared" -******** ocamlopt.byte -libraries += "dynlink" -program = "${test_build_directory}/main.exe" -all_modules = "dyn.cmx" -flags = "" -********* run -output = "main.output" -********** check-program-output + include dynlink; + readonly_files = "lib.ml lib2.ml test.c"; + ld_library_path += "${test_build_directory}"; + shared-libraries; + { + setup-ocamlc.byte-build-env; + compile_only = "true"; + all_modules = "lib.ml lib2.ml test.c dyn.ml"; + ocamlc.byte; + program = "lib"; + modules = "lib.cmo test.${objext}"; + compile_only = "false"; + ocamlmklib; + program = "lib2.cma"; + libraries = ""; + all_modules = "lib2.cmo"; + compile_only = "false"; + flags = "-a"; + ocamlc.byte; + libraries += "dynlink"; + program = "${test_build_directory}/main.exe"; + all_modules = "dyn.cmo"; + flags = ""; + ocamlc.byte; + output = "main.output"; + run; + check-program-output; + }{ + native-dynlink; + setup-ocamlopt.byte-build-env; + compile_only = "true"; + all_modules = "lib.ml lib2.ml test.c dyn.ml"; + ocamlopt.byte; + program = "test"; + modules = "test.${objext}"; + compile_only = "false"; + ocamlmklib; + program = "lib.cmxs"; + libraries = ""; + flags = "-shared -cclib -L. -cclib -ltest"; + all_modules = "lib.cmx"; + compile_only = "false"; + ocamlopt.byte; + program = "lib2.cmxs"; + all_modules = "lib2.cmx"; + compile_only = "false"; + flags = "-shared"; + ocamlopt.byte; + libraries += "dynlink"; + program = "${test_build_directory}/main.exe"; + all_modules = "dyn.cmx"; + flags = ""; + ocamlopt.byte; + output = "main.output"; + run; + check-program-output; + } *) let () = Dynlink.allow_unsafe_modules true; diff --git a/testsuite/tests/lib-dynlink-private/test.ml b/testsuite/tests/lib-dynlink-private/test.ml index 5554ba74df..193e5308ce 100644 --- a/testsuite/tests/lib-dynlink-private/test.ml +++ b/testsuite/tests/lib-dynlink-private/test.ml @@ -1,170 +1,169 @@ (* TEST - -include dynlink -libraries = "" -readonly_files = "sheep.mli sheep.ml pig.mli" -subdirectories = "plugin1 plugin2 plugin2b plugin2c plugin3 plugin4 \ - plugin5 plugin6" - -* shared-libraries -** setup-ocamlc.byte-build-env -*** ocamlc.byte -module = "sheep.mli" -**** ocamlc.byte -module = "sheep.ml" -***** ocamlc.byte -module = "pig.mli" -****** ocamlc.byte -module = "test.ml" -******* ocamlc.byte -module = "plugin1/sheep.mli" -******** ocamlc.byte -flags = "-I plugin1" -module = "plugin1/sheep.ml" -********* ocamlc.byte -flags = "" -module = "plugin2/cow.mli" -********** ocamlc.byte -flags = "-I plugin2" -module = "plugin2/cow.ml" -*********** ocamlc.byte -flags = "" -module = "plugin2b/cow.mli" -************ ocamlc.byte -flags = "-I plugin2b" -module = "plugin2b/cow.ml" -************* ocamlc.byte -flags = "" -module = "plugin2c/cow.mli" -************** ocamlc.byte -flags = "-I plugin2c" -module = "plugin2c/cow.ml" -*************** ocamlc.byte -flags = "" -module = "plugin3/pig.mli" -**************** ocamlc.byte -flags = "-I plugin3" -module = "plugin3/pig.ml" -***************** ocamlc.byte -flags = "" -module = "plugin4/chicken.mli" -****************** ocamlc.byte -flags = "-I plugin4" -module = "plugin4/chicken.ml" -******************* ocamlc.byte -flags = "" -module = "plugin5/chicken.mli" -******************** ocamlc.byte -flags = "-I plugin5" -module = "plugin5/chicken.ml" -********************* ocamlc.byte -flags = "" -module = "plugin6/pheasant.mli" -********************** ocamlc.byte -flags = "-I plugin6" -module = "plugin6/pheasant.ml" -*********************** ocamlc.byte -flags = "" -module = "plugin6/partridge.mli" -************************ ocamlc.byte -flags = "-I plugin6" -module = "plugin6/partridge.ml" -************************* ocamlc.byte -flags = "" -program = "./test.byte.exe" -libraries = "dynlink" -all_modules = "sheep.cmo test.cmo" -module = "" -************************** run - -** native-dynlink -*** setup-ocamlopt.byte-build-env -**** ocamlopt.byte -module = "sheep.mli" -***** ocamlopt.byte -module = "sheep.ml" -****** ocamlopt.byte -module = "pig.mli" -******* ocamlopt.byte -module = "test.ml" -******** ocamlopt.byte -flags = "" -module = "plugin1/sheep.mli" -********* ocamlopt.byte -program = "plugin1/sheep.cmxs" -flags = "-I plugin1 -shared" -module = "" -all_modules = "plugin1/sheep.ml" -********** ocamlopt.byte -flags = "" -module = "plugin2/cow.mli" -*********** ocamlopt.byte -program = "plugin2/cow.cmxs" -flags = "-I plugin2 -shared" -module = "" -all_modules = "plugin2/cow.ml" -************ ocamlopt.byte -flags = "" -module = "plugin2b/cow.mli" -************* ocamlopt.byte -program = "plugin2b/cow.cmxs" -flags = "-I plugin2b -shared" -module = "" -all_modules = "plugin2b/cow.ml" -************** ocamlopt.byte -flags = "" -module = "plugin2c/cow.mli" -*************** ocamlopt.byte -program = "plugin2c/cow.cmxs" -flags = "-I plugin2c -shared" -module = "" -all_modules = "plugin2c/cow.ml" -**************** ocamlopt.byte -flags = "" -module = "plugin3/pig.mli" -***************** ocamlopt.byte -program = "plugin3/pig.cmxs" -flags = "-I plugin3 -shared" -module = "" -all_modules = "plugin3/pig.ml" -****************** ocamlopt.byte -flags = "" -module = "plugin4/chicken.mli" -******************* ocamlopt.byte -program = "plugin4/chicken.cmxs" -flags = "-I plugin4 -shared" -module = "" -all_modules = "plugin4/chicken.ml" -******************** ocamlopt.byte -flags = "" -module = "plugin5/chicken.mli" -********************* ocamlopt.byte -program = "plugin5/chicken.cmxs" -flags = "-I plugin5 -shared" -module = "" -all_modules = "plugin5/chicken.ml" -********************** ocamlopt.byte -flags = "" -module = "plugin6/pheasant.mli" -*********************** ocamlopt.byte -program = "plugin6/pheasant.cmxs" -flags = "-I plugin6 -shared" -module = "" -all_modules = "plugin6/pheasant.ml" -************************ ocamlopt.byte -flags = "" -module = "plugin6/partridge.mli" -************************* ocamlopt.byte -program = "plugin6/partridge.cmxs" -flags = "-I plugin6 -shared" -module = "" -all_modules = "plugin6/partridge.ml" -************************** ocamlopt.byte -flags = "" -program = "./test.opt.exe" -libraries = "dynlink" -all_modules = "sheep.cmx test.cmx" -*************************** run + include dynlink; + libraries = ""; + readonly_files = "sheep.mli sheep.ml pig.mli"; + subdirectories = "plugin1 plugin2 plugin2b plugin2c plugin3 plugin4 plugin5 plugin6"; + shared-libraries; + { + setup-ocamlc.byte-build-env; + module = "sheep.mli"; + ocamlc.byte; + module = "sheep.ml"; + ocamlc.byte; + module = "pig.mli"; + ocamlc.byte; + module = "test.ml"; + ocamlc.byte; + module = "plugin1/sheep.mli"; + ocamlc.byte; + flags = "-I plugin1"; + module = "plugin1/sheep.ml"; + ocamlc.byte; + flags = ""; + module = "plugin2/cow.mli"; + ocamlc.byte; + flags = "-I plugin2"; + module = "plugin2/cow.ml"; + ocamlc.byte; + flags = ""; + module = "plugin2b/cow.mli"; + ocamlc.byte; + flags = "-I plugin2b"; + module = "plugin2b/cow.ml"; + ocamlc.byte; + flags = ""; + module = "plugin2c/cow.mli"; + ocamlc.byte; + flags = "-I plugin2c"; + module = "plugin2c/cow.ml"; + ocamlc.byte; + flags = ""; + module = "plugin3/pig.mli"; + ocamlc.byte; + flags = "-I plugin3"; + module = "plugin3/pig.ml"; + ocamlc.byte; + flags = ""; + module = "plugin4/chicken.mli"; + ocamlc.byte; + flags = "-I plugin4"; + module = "plugin4/chicken.ml"; + ocamlc.byte; + flags = ""; + module = "plugin5/chicken.mli"; + ocamlc.byte; + flags = "-I plugin5"; + module = "plugin5/chicken.ml"; + ocamlc.byte; + flags = ""; + module = "plugin6/pheasant.mli"; + ocamlc.byte; + flags = "-I plugin6"; + module = "plugin6/pheasant.ml"; + ocamlc.byte; + flags = ""; + module = "plugin6/partridge.mli"; + ocamlc.byte; + flags = "-I plugin6"; + module = "plugin6/partridge.ml"; + ocamlc.byte; + flags = ""; + program = "./test.byte.exe"; + libraries = "dynlink"; + all_modules = "sheep.cmo test.cmo"; + module = ""; + ocamlc.byte; + run; + }{ + native-dynlink; + setup-ocamlopt.byte-build-env; + module = "sheep.mli"; + ocamlopt.byte; + module = "sheep.ml"; + ocamlopt.byte; + module = "pig.mli"; + ocamlopt.byte; + module = "test.ml"; + ocamlopt.byte; + flags = ""; + module = "plugin1/sheep.mli"; + ocamlopt.byte; + program = "plugin1/sheep.cmxs"; + flags = "-I plugin1 -shared"; + module = ""; + all_modules = "plugin1/sheep.ml"; + ocamlopt.byte; + flags = ""; + module = "plugin2/cow.mli"; + ocamlopt.byte; + program = "plugin2/cow.cmxs"; + flags = "-I plugin2 -shared"; + module = ""; + all_modules = "plugin2/cow.ml"; + ocamlopt.byte; + flags = ""; + module = "plugin2b/cow.mli"; + ocamlopt.byte; + program = "plugin2b/cow.cmxs"; + flags = "-I plugin2b -shared"; + module = ""; + all_modules = "plugin2b/cow.ml"; + ocamlopt.byte; + flags = ""; + module = "plugin2c/cow.mli"; + ocamlopt.byte; + program = "plugin2c/cow.cmxs"; + flags = "-I plugin2c -shared"; + module = ""; + all_modules = "plugin2c/cow.ml"; + ocamlopt.byte; + flags = ""; + module = "plugin3/pig.mli"; + ocamlopt.byte; + program = "plugin3/pig.cmxs"; + flags = "-I plugin3 -shared"; + module = ""; + all_modules = "plugin3/pig.ml"; + ocamlopt.byte; + flags = ""; + module = "plugin4/chicken.mli"; + ocamlopt.byte; + program = "plugin4/chicken.cmxs"; + flags = "-I plugin4 -shared"; + module = ""; + all_modules = "plugin4/chicken.ml"; + ocamlopt.byte; + flags = ""; + module = "plugin5/chicken.mli"; + ocamlopt.byte; + program = "plugin5/chicken.cmxs"; + flags = "-I plugin5 -shared"; + module = ""; + all_modules = "plugin5/chicken.ml"; + ocamlopt.byte; + flags = ""; + module = "plugin6/pheasant.mli"; + ocamlopt.byte; + program = "plugin6/pheasant.cmxs"; + flags = "-I plugin6 -shared"; + module = ""; + all_modules = "plugin6/pheasant.ml"; + ocamlopt.byte; + flags = ""; + module = "plugin6/partridge.mli"; + ocamlopt.byte; + program = "plugin6/partridge.cmxs"; + flags = "-I plugin6 -shared"; + module = ""; + all_modules = "plugin6/partridge.ml"; + ocamlopt.byte; + flags = ""; + program = "./test.opt.exe"; + libraries = "dynlink"; + all_modules = "sheep.cmx test.cmx"; + ocamlopt.byte; + run; + } *) let () = Sheep.baa Sheep.s (* Use Sheep module *) diff --git a/testsuite/tests/lib-either/test.ml b/testsuite/tests/lib-either/test.ml index 2a62f38919..5cdaa3837d 100644 --- a/testsuite/tests/lib-either/test.ml +++ b/testsuite/tests/lib-either/test.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) open Either;; diff --git a/testsuite/tests/lib-filename/extension.ml b/testsuite/tests/lib-filename/extension.ml index ae7c8b61d4..3b42056719 100644 --- a/testsuite/tests/lib-filename/extension.ml +++ b/testsuite/tests/lib-filename/extension.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) let () = let test f e = diff --git a/testsuite/tests/lib-filename/null.ml b/testsuite/tests/lib-filename/null.ml index 048e36622e..ecad3c7836 100644 --- a/testsuite/tests/lib-filename/null.ml +++ b/testsuite/tests/lib-filename/null.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) let () = let ic = open_in Filename.null in diff --git a/testsuite/tests/lib-filename/quotecommand.ml b/testsuite/tests/lib-filename/quotecommand.ml index 5e5059c02a..7034c36922 100644 --- a/testsuite/tests/lib-filename/quotecommand.ml +++ b/testsuite/tests/lib-filename/quotecommand.ml @@ -1,31 +1,30 @@ (* TEST - -readonly_files = "myecho.ml" - -* setup-ocamlc.byte-build-env -program = "${test_build_directory}/quotecommand.byte" -** ocamlc.byte -program = "${test_build_directory}/myecho.exe" -all_modules = "myecho.ml" -*** ocamlc.byte -program = "${test_build_directory}/quotecommand.byte" -all_modules= "quotecommand.ml" -**** check-ocamlc.byte-output -***** run -****** check-program-output - -* setup-ocamlopt.byte-build-env -program = "${test_build_directory}/quotecommand.opt" -** ocamlopt.byte -program = "${test_build_directory}/myecho.exe" -all_modules = "myecho.ml" -*** ocamlopt.byte -program = "${test_build_directory}/quotecommand.opt" -all_modules= "quotecommand.ml" -**** check-ocamlopt.byte-output -***** run -****** check-program-output - + readonly_files = "myecho.ml"; + { + program = "${test_build_directory}/quotecommand.byte"; + setup-ocamlc.byte-build-env; + program = "${test_build_directory}/myecho.exe"; + all_modules = "myecho.ml"; + ocamlc.byte; + program = "${test_build_directory}/quotecommand.byte"; + all_modules = "quotecommand.ml"; + ocamlc.byte; + check-ocamlc.byte-output; + run; + check-program-output; + }{ + program = "${test_build_directory}/quotecommand.opt"; + setup-ocamlopt.byte-build-env; + program = "${test_build_directory}/myecho.exe"; + all_modules = "myecho.ml"; + ocamlopt.byte; + program = "${test_build_directory}/quotecommand.opt"; + all_modules = "quotecommand.ml"; + ocamlopt.byte; + check-ocamlopt.byte-output; + run; + check-program-output; + } *) open Printf diff --git a/testsuite/tests/lib-filename/suffix.ml b/testsuite/tests/lib-filename/suffix.ml index 3faa5c94fe..071df44653 100644 --- a/testsuite/tests/lib-filename/suffix.ml +++ b/testsuite/tests/lib-filename/suffix.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) let () = let test ~suffix name exp = diff --git a/testsuite/tests/lib-filename/temp.ml b/testsuite/tests/lib-filename/temp.ml index d0bbbe9cf2..75d79417e1 100644 --- a/testsuite/tests/lib-filename/temp.ml +++ b/testsuite/tests/lib-filename/temp.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) let () = let tmpdir1 = ref "" in diff --git a/testsuite/tests/lib-float/test.ml b/testsuite/tests/lib-float/test.ml index ac3e91b55e..8cdbd9afe6 100644 --- a/testsuite/tests/lib-float/test.ml +++ b/testsuite/tests/lib-float/test.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) let is_nan2 (x, y) = Float.is_nan x && Float.is_nan y diff --git a/testsuite/tests/lib-floatarray/floatarray.ml b/testsuite/tests/lib-floatarray/floatarray.ml index 379b76bc78..564c325d7c 100644 --- a/testsuite/tests/lib-floatarray/floatarray.ml +++ b/testsuite/tests/lib-floatarray/floatarray.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) open Printf diff --git a/testsuite/tests/lib-format/pr6824.ml b/testsuite/tests/lib-format/pr6824.ml index 7dc9208380..342ebd9a11 100644 --- a/testsuite/tests/lib-format/pr6824.ml +++ b/testsuite/tests/lib-format/pr6824.ml @@ -1,5 +1,5 @@ (* TEST - include testing + include testing; *) let f = Format.sprintf "[%i]";; diff --git a/testsuite/tests/lib-format/print_array.ml b/testsuite/tests/lib-format/print_array.ml index dc6481c884..5efce52758 100644 --- a/testsuite/tests/lib-format/print_array.ml +++ b/testsuite/tests/lib-format/print_array.ml @@ -1,5 +1,5 @@ (* TEST - include testing + include testing; *) (* diff --git a/testsuite/tests/lib-format/print_seq.ml b/testsuite/tests/lib-format/print_seq.ml index 4113ded9ad..72f99f02d2 100644 --- a/testsuite/tests/lib-format/print_seq.ml +++ b/testsuite/tests/lib-format/print_seq.ml @@ -1,5 +1,5 @@ (* TEST - include testing + include testing; *) (* diff --git a/testsuite/tests/lib-format/tformat.ml b/testsuite/tests/lib-format/tformat.ml index e0118387a0..98ad1afdab 100644 --- a/testsuite/tests/lib-format/tformat.ml +++ b/testsuite/tests/lib-format/tformat.ml @@ -1,6 +1,6 @@ (* TEST - include testing - flags = "-no-strict-formats" + include testing; + flags = "-no-strict-formats"; *) (* diff --git a/testsuite/tests/lib-fun/test.ml b/testsuite/tests/lib-fun/test.ml index ba534db262..b0c7914697 100644 --- a/testsuite/tests/lib-fun/test.ml +++ b/testsuite/tests/lib-fun/test.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) let test_id () = assert (Fun.id true = true); diff --git a/testsuite/tests/lib-hashtbl/compatibility.ml b/testsuite/tests/lib-hashtbl/compatibility.ml index 9ad3a477f3..39477a62ee 100644 --- a/testsuite/tests/lib-hashtbl/compatibility.ml +++ b/testsuite/tests/lib-hashtbl/compatibility.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) let check_contents (h: (string, int) Hashtbl.t) (expected: (string * int) list) = diff --git a/testsuite/tests/lib-hashtbl/hfun.ml b/testsuite/tests/lib-hashtbl/hfun.ml index 3e15596e85..ae0634dc11 100644 --- a/testsuite/tests/lib-hashtbl/hfun.ml +++ b/testsuite/tests/lib-hashtbl/hfun.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) (* Testing the hash function Hashtbl.hash *) (* What is tested: diff --git a/testsuite/tests/lib-hashtbl/htbl.ml b/testsuite/tests/lib-hashtbl/htbl.ml index efdc5fba28..4af75a9f02 100644 --- a/testsuite/tests/lib-hashtbl/htbl.ml +++ b/testsuite/tests/lib-hashtbl/htbl.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) (* Hashtable operations, using maps as a reference *) diff --git a/testsuite/tests/lib-int/test.ml b/testsuite/tests/lib-int/test.ml index db510fe5b1..2fdee39520 100644 --- a/testsuite/tests/lib-int/test.ml +++ b/testsuite/tests/lib-int/test.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) let test_consts () = assert (Int.zero = 0); diff --git a/testsuite/tests/lib-int64/issue9460.ml b/testsuite/tests/lib-int64/issue9460.ml index aacbe6189b..f05005cada 100644 --- a/testsuite/tests/lib-int64/issue9460.ml +++ b/testsuite/tests/lib-int64/issue9460.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) (* See https://github.com/ocaml/ocaml/issues/9460 This test comes from Richard Jones diff --git a/testsuite/tests/lib-int64/test.ml b/testsuite/tests/lib-int64/test.ml index 6bb0a5dc10..c518ad9a08 100644 --- a/testsuite/tests/lib-int64/test.ml +++ b/testsuite/tests/lib-int64/test.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) let test_consts () = assert (Int64.zero = 0L); diff --git a/testsuite/tests/lib-internalformat/test.ml b/testsuite/tests/lib-internalformat/test.ml index 9f81335339..8b3d3c5275 100644 --- a/testsuite/tests/lib-internalformat/test.ml +++ b/testsuite/tests/lib-internalformat/test.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) let inspect (format : _ format6) = diff --git a/testsuite/tests/lib-lazy/test.ml b/testsuite/tests/lib-lazy/test.ml index c6659f2207..cd2c351078 100644 --- a/testsuite/tests/lib-lazy/test.ml +++ b/testsuite/tests/lib-lazy/test.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* expect-tests currently do not collect I/O, diff --git a/testsuite/tests/lib-list/test.ml b/testsuite/tests/lib-list/test.ml index 3d762e7bca..46b73b0720 100644 --- a/testsuite/tests/lib-list/test.ml +++ b/testsuite/tests/lib-list/test.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) let is_even x = (x mod 2 = 0) diff --git a/testsuite/tests/lib-marshal/intext.ml b/testsuite/tests/lib-marshal/intext.ml index 8f9a26133d..fc7ffbe2aa 100644 --- a/testsuite/tests/lib-marshal/intext.ml +++ b/testsuite/tests/lib-marshal/intext.ml @@ -1,5 +1,5 @@ (* TEST - modules = "intextaux.c" + modules = "intextaux.c"; *) (* Test for output_value / input_value *) diff --git a/testsuite/tests/lib-marshal/intext_par.ml b/testsuite/tests/lib-marshal/intext_par.ml index 8db6e91a5a..3aade5bacc 100644 --- a/testsuite/tests/lib-marshal/intext_par.ml +++ b/testsuite/tests/lib-marshal/intext_par.ml @@ -1,5 +1,5 @@ (* TEST - modules = "intextaux_par.c" + modules = "intextaux_par.c"; *) (* Test for output_value / input_value *) diff --git a/testsuite/tests/lib-obj/new_obj.ml b/testsuite/tests/lib-obj/new_obj.ml index 049a300f55..ae28f52ea8 100644 --- a/testsuite/tests/lib-obj/new_obj.ml +++ b/testsuite/tests/lib-obj/new_obj.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) let _ = diff --git a/testsuite/tests/lib-obj/reachable_words.ml b/testsuite/tests/lib-obj/reachable_words.ml index 8ec724343c..42bb2430ae 100644 --- a/testsuite/tests/lib-obj/reachable_words.ml +++ b/testsuite/tests/lib-obj/reachable_words.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) diff --git a/testsuite/tests/lib-obj/reachable_words_bug.ml b/testsuite/tests/lib-obj/reachable_words_bug.ml index 15969eb421..54e2aadd64 100644 --- a/testsuite/tests/lib-obj/reachable_words_bug.ml +++ b/testsuite/tests/lib-obj/reachable_words_bug.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) let _ = (* In 4.13 this causes Obj.reachable_words to segfault diff --git a/testsuite/tests/lib-obj/with_tag.ml b/testsuite/tests/lib-obj/with_tag.ml index a4b69ea1d4..66137e2469 100644 --- a/testsuite/tests/lib-obj/with_tag.ml +++ b/testsuite/tests/lib-obj/with_tag.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) type t = | A of string * float diff --git a/testsuite/tests/lib-option/test.ml b/testsuite/tests/lib-option/test.ml index 316e3eae97..5383c382c2 100644 --- a/testsuite/tests/lib-option/test.ml +++ b/testsuite/tests/lib-option/test.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) let strf = Printf.sprintf let assert_raise_invalid_argument f v = diff --git a/testsuite/tests/lib-printf/pr6534.ml b/testsuite/tests/lib-printf/pr6534.ml index b475c58ab0..f4b4fb8d5a 100644 --- a/testsuite/tests/lib-printf/pr6534.ml +++ b/testsuite/tests/lib-printf/pr6534.ml @@ -1,6 +1,6 @@ (* TEST - include testing - flags = "-no-strict-formats" + include testing; + flags = "-no-strict-formats"; *) (* these are not valid under -strict-formats, but we test them here diff --git a/testsuite/tests/lib-printf/pr6938.ml b/testsuite/tests/lib-printf/pr6938.ml index 5331b77e9f..cf90e0a8dc 100644 --- a/testsuite/tests/lib-printf/pr6938.ml +++ b/testsuite/tests/lib-printf/pr6938.ml @@ -1,6 +1,6 @@ (* TEST - include testing - flags = "-no-strict-formats" + include testing; + flags = "-no-strict-formats"; *) (* these are not valid under -strict-formats, but we test them here diff --git a/testsuite/tests/lib-printf/tprintf.ml b/testsuite/tests/lib-printf/tprintf.ml index e3887bd807..4241a804f7 100644 --- a/testsuite/tests/lib-printf/tprintf.ml +++ b/testsuite/tests/lib-printf/tprintf.ml @@ -1,6 +1,6 @@ (* TEST - include testing - flags = "-no-strict-formats" + include testing; + flags = "-no-strict-formats"; *) (* diff --git a/testsuite/tests/lib-queue/test.ml b/testsuite/tests/lib-queue/test.ml index ac05f4e303..cff8e2cd65 100644 --- a/testsuite/tests/lib-queue/test.ml +++ b/testsuite/tests/lib-queue/test.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) module Q = struct include Queue diff --git a/testsuite/tests/lib-random/chi2.ml b/testsuite/tests/lib-random/chi2.ml index 42d2b1d7cd..3804f6511c 100644 --- a/testsuite/tests/lib-random/chi2.ml +++ b/testsuite/tests/lib-random/chi2.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) (* A basic chi-square test to detect simple errors in the Random module. *) diff --git a/testsuite/tests/lib-random/defaultinit.ml b/testsuite/tests/lib-random/defaultinit.ml index df3550374e..79179d9891 100644 --- a/testsuite/tests/lib-random/defaultinit.ml +++ b/testsuite/tests/lib-random/defaultinit.ml @@ -1,5 +1,5 @@ (* TEST - include testing + include testing; *) (* Check that the numbers drawn from the default state are the same diff --git a/testsuite/tests/lib-random/parallel.ml b/testsuite/tests/lib-random/parallel.ml index 68f567abec..9a8f1c96ae 100644 --- a/testsuite/tests/lib-random/parallel.ml +++ b/testsuite/tests/lib-random/parallel.ml @@ -1,9 +1,12 @@ (* TEST - include unix - * libunix - ** bytecode - ** native - *) + include unix; + libunix; + { + bytecode; + }{ + native; + } +*) let () = Random.init 42 diff --git a/testsuite/tests/lib-random/selfinit.ml b/testsuite/tests/lib-random/selfinit.ml index 1664907de4..eab1bfaf1a 100644 --- a/testsuite/tests/lib-random/selfinit.ml +++ b/testsuite/tests/lib-random/selfinit.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) (* Test that two Random.self_init() in close succession will not result in the same PRNG state. diff --git a/testsuite/tests/lib-random/testvectors.ml b/testsuite/tests/lib-random/testvectors.ml index b8f09ae058..2ff5e0970d 100644 --- a/testsuite/tests/lib-random/testvectors.ml +++ b/testsuite/tests/lib-random/testvectors.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) (* Check the numbers drawn from a known state against the numbers obtained from the reference Java implementation. *) diff --git a/testsuite/tests/lib-result/test.ml b/testsuite/tests/lib-result/test.ml index 6e7a5cc8cf..c32c7dc395 100644 --- a/testsuite/tests/lib-result/test.ml +++ b/testsuite/tests/lib-result/test.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) let strf = Printf.sprintf let assert_raise_invalid_argument f v = diff --git a/testsuite/tests/lib-runtime-events/test.ml b/testsuite/tests/lib-runtime-events/test.ml index db08937089..2e7e1b90ab 100644 --- a/testsuite/tests/lib-runtime-events/test.ml +++ b/testsuite/tests/lib-runtime-events/test.ml @@ -1,6 +1,6 @@ (* TEST -modules = "stubs.c" -include runtime_events + modules = "stubs.c"; + include runtime_events; *) external start_runtime_events : unit -> unit = "start_runtime_events" diff --git a/testsuite/tests/lib-runtime-events/test_caml.ml b/testsuite/tests/lib-runtime-events/test_caml.ml index 1e96998149..4d656f3e01 100644 --- a/testsuite/tests/lib-runtime-events/test_caml.ml +++ b/testsuite/tests/lib-runtime-events/test_caml.ml @@ -1,5 +1,5 @@ (* TEST -include runtime_events + include runtime_events; *) open Runtime_events diff --git a/testsuite/tests/lib-runtime-events/test_caml_counters.ml b/testsuite/tests/lib-runtime-events/test_caml_counters.ml index af43fd47af..75fa99341d 100644 --- a/testsuite/tests/lib-runtime-events/test_caml_counters.ml +++ b/testsuite/tests/lib-runtime-events/test_caml_counters.ml @@ -1,5 +1,5 @@ (* TEST -include runtime_events + include runtime_events; *) open Runtime_events diff --git a/testsuite/tests/lib-runtime-events/test_caml_exception.ml b/testsuite/tests/lib-runtime-events/test_caml_exception.ml index e1df5aee0b..59adfe32c2 100644 --- a/testsuite/tests/lib-runtime-events/test_caml_exception.ml +++ b/testsuite/tests/lib-runtime-events/test_caml_exception.ml @@ -1,5 +1,5 @@ (* TEST -include runtime_events + include runtime_events; *) open Runtime_events diff --git a/testsuite/tests/lib-runtime-events/test_caml_parallel.ml b/testsuite/tests/lib-runtime-events/test_caml_parallel.ml index 76cad340d8..4394355924 100644 --- a/testsuite/tests/lib-runtime-events/test_caml_parallel.ml +++ b/testsuite/tests/lib-runtime-events/test_caml_parallel.ml @@ -1,5 +1,5 @@ (* TEST -include runtime_events + include runtime_events; *) open Runtime_events diff --git a/testsuite/tests/lib-runtime-events/test_caml_reentry.ml b/testsuite/tests/lib-runtime-events/test_caml_reentry.ml index d69042e354..81e38e208a 100644 --- a/testsuite/tests/lib-runtime-events/test_caml_reentry.ml +++ b/testsuite/tests/lib-runtime-events/test_caml_reentry.ml @@ -1,5 +1,5 @@ (* TEST -include runtime_events + include runtime_events; *) open Runtime_events diff --git a/testsuite/tests/lib-runtime-events/test_caml_runparams.ml b/testsuite/tests/lib-runtime-events/test_caml_runparams.ml index a574e7d341..19612a595a 100644 --- a/testsuite/tests/lib-runtime-events/test_caml_runparams.ml +++ b/testsuite/tests/lib-runtime-events/test_caml_runparams.ml @@ -1,6 +1,6 @@ (* TEST -include runtime_events -ocamlrunparam += ",e=4" + include runtime_events; + ocamlrunparam += ",e=4"; *) (* We set the ring buffer size smaller and witness that we do indeed diff --git a/testsuite/tests/lib-runtime-events/test_caml_slot_reuse.ml b/testsuite/tests/lib-runtime-events/test_caml_slot_reuse.ml index 34b034a8e8..cbbfa9a863 100644 --- a/testsuite/tests/lib-runtime-events/test_caml_slot_reuse.ml +++ b/testsuite/tests/lib-runtime-events/test_caml_slot_reuse.ml @@ -1,5 +1,5 @@ (* TEST -include runtime_events + include runtime_events; *) open Runtime_events diff --git a/testsuite/tests/lib-runtime-events/test_caml_stubs_gc.ml b/testsuite/tests/lib-runtime-events/test_caml_stubs_gc.ml index 35ddd983a1..6ea181f17c 100644 --- a/testsuite/tests/lib-runtime-events/test_caml_stubs_gc.ml +++ b/testsuite/tests/lib-runtime-events/test_caml_stubs_gc.ml @@ -1,5 +1,5 @@ (* TEST -include runtime_events + include runtime_events; *) open Runtime_events diff --git a/testsuite/tests/lib-runtime-events/test_dropped_events.ml b/testsuite/tests/lib-runtime-events/test_dropped_events.ml index 7443833499..04df10ef9f 100644 --- a/testsuite/tests/lib-runtime-events/test_dropped_events.ml +++ b/testsuite/tests/lib-runtime-events/test_dropped_events.ml @@ -1,10 +1,13 @@ (* TEST - include runtime_events - include unix - set OCAMLRUNPARAM = "e=6" - * libunix - ** native - ** bytecode + include runtime_events; + include unix; + set OCAMLRUNPARAM = "e=6"; + libunix; + { + native; + }{ + bytecode; + } *) type Runtime_events.User.tag += Ev diff --git a/testsuite/tests/lib-runtime-events/test_env_start.ml b/testsuite/tests/lib-runtime-events/test_env_start.ml index 6b6bca5b09..5562d26707 100644 --- a/testsuite/tests/lib-runtime-events/test_env_start.ml +++ b/testsuite/tests/lib-runtime-events/test_env_start.ml @@ -1,6 +1,6 @@ (* TEST -include runtime_events -set OCAML_RUNTIME_EVENTS_START = "1" + include runtime_events; + set OCAML_RUNTIME_EVENTS_START = "1"; *) (* In this test the runtime_events should already be started by the environment diff --git a/testsuite/tests/lib-runtime-events/test_external.ml b/testsuite/tests/lib-runtime-events/test_external.ml index ecea4b7e13..df285e78cf 100644 --- a/testsuite/tests/lib-runtime-events/test_external.ml +++ b/testsuite/tests/lib-runtime-events/test_external.ml @@ -1,9 +1,13 @@ (* TEST - include runtime_events - include unix - * libunix - ** bytecode - ** native *) + include runtime_events; + include unix; + libunix; + { + bytecode; + }{ + native; + } +*) let got_major = ref false let got_minor = ref false diff --git a/testsuite/tests/lib-runtime-events/test_external_preserve.ml b/testsuite/tests/lib-runtime-events/test_external_preserve.ml index 18c2ac578b..d5dd87c14b 100644 --- a/testsuite/tests/lib-runtime-events/test_external_preserve.ml +++ b/testsuite/tests/lib-runtime-events/test_external_preserve.ml @@ -1,10 +1,14 @@ (* TEST - include runtime_events - include unix - set OCAML_RUNTIME_EVENTS_PRESERVE = "1" - * libunix - ** bytecode - ** native *) + include runtime_events; + include unix; + set OCAML_RUNTIME_EVENTS_PRESERVE = "1"; + libunix; + { + bytecode; + }{ + native; + } +*) (* this tests the preservation of ring buffers after termination *) diff --git a/testsuite/tests/lib-runtime-events/test_fork.ml b/testsuite/tests/lib-runtime-events/test_fork.ml index 87f556a659..6d6ca1ef09 100644 --- a/testsuite/tests/lib-runtime-events/test_fork.ml +++ b/testsuite/tests/lib-runtime-events/test_fork.ml @@ -1,9 +1,13 @@ (* TEST - include runtime_events - include unix - * libunix - ** bytecode - ** native *) + include runtime_events; + include unix; + libunix; + { + bytecode; + }{ + native; + } +*) let got_start = ref false let got_fork_child = ref false diff --git a/testsuite/tests/lib-runtime-events/test_instrumented.ml b/testsuite/tests/lib-runtime-events/test_instrumented.ml index 94727d13fd..5c49db90af 100644 --- a/testsuite/tests/lib-runtime-events/test_instrumented.ml +++ b/testsuite/tests/lib-runtime-events/test_instrumented.ml @@ -1,9 +1,8 @@ (* TEST - include runtime_events - flags = "-runtime-variant=i" - - * instrumented-runtime - ** native + include runtime_events; + flags = "-runtime-variant=i"; + instrumented-runtime; + native; *) open Runtime_events diff --git a/testsuite/tests/lib-runtime-events/test_user_event.ml b/testsuite/tests/lib-runtime-events/test_user_event.ml index a4cb09175b..4c9e90c919 100644 --- a/testsuite/tests/lib-runtime-events/test_user_event.ml +++ b/testsuite/tests/lib-runtime-events/test_user_event.ml @@ -1,5 +1,5 @@ (* TEST -include runtime_events + include runtime_events; *) open Runtime_events diff --git a/testsuite/tests/lib-runtime-events/test_user_event_unknown.ml b/testsuite/tests/lib-runtime-events/test_user_event_unknown.ml index f5a63d46fd..447b7b5c55 100644 --- a/testsuite/tests/lib-runtime-events/test_user_event_unknown.ml +++ b/testsuite/tests/lib-runtime-events/test_user_event_unknown.ml @@ -1,10 +1,13 @@ (* TEST - include runtime_events - include unix - set OCAML_RUNTIME_EVENTS_PRESERVE = "1" - * libunix - ** bytecode - ** native + include runtime_events; + include unix; + set OCAML_RUNTIME_EVENTS_PRESERVE = "1"; + libunix; + { + bytecode; + }{ + native; + } *) open Runtime_events diff --git a/testsuite/tests/lib-scanf-2/tscanf2_master.ml b/testsuite/tests/lib-scanf-2/tscanf2_master.ml index d364ceabcd..7d1e8ee7f8 100644 --- a/testsuite/tests/lib-scanf-2/tscanf2_master.ml +++ b/testsuite/tests/lib-scanf-2/tscanf2_master.ml @@ -1,59 +1,36 @@ (* TEST - -modules = "tscanf2_io.ml" -* hasunix -include unix -readonly_files = "tscanf2_worker.ml" -reference = "${test_source_directory}/tscanf2.reference" - -(* The bytcode test *) - -** setup-ocamlc.byte-build-env - -program = "${test_build_directory}/master.byte" - -*** ocamlc.byte (* Compiles the master *) - -**** ocamlc.byte (* Compiles the worker *) - -all_modules = "tscanf2_io.cmo tscanf2_worker.ml" - -program = "${test_build_directory}/worker.byte" - -***** check-ocamlc.byte-output - -****** run - -program = "${test_build_directory}/master.byte" - -arguments = "${test_build_directory}/worker.byte" - -******* check-program-output - -(* The native test *) - -** setup-ocamlopt.byte-build-env - -program = "${test_build_directory}/master.opt" - -*** ocamlopt.byte (* Compiles the master *) - -**** ocamlopt.byte (* Compiles the worker *) - -all_modules = "tscanf2_io.cmx tscanf2_worker.ml" - -program = "${test_build_directory}/worker.opt" - -***** check-ocamlopt.byte-output - -****** run - -program = "${test_build_directory}/master.opt" - -arguments = "${test_build_directory}/worker.opt" - -******* check-program-output - + modules = "tscanf2_io.ml"; + include unix; + readonly_files = "tscanf2_worker.ml"; + reference = "${test_source_directory}/tscanf2.reference"; + hasunix; + { + (* The bytecode test *) + program = "${test_build_directory}/master.byte"; + setup-ocamlc.byte-build-env; + ocamlc.byte; (* Compiles the master *) + all_modules = "tscanf2_io.cmo tscanf2_worker.ml"; + program = "${test_build_directory}/worker.byte"; + ocamlc.byte; (* Compiles the worker *) + check-ocamlc.byte-output; + program = "${test_build_directory}/master.byte"; + arguments = "${test_build_directory}/worker.byte"; + run; + check-program-output; + }{ + (* The native test *) + program = "${test_build_directory}/master.opt"; + setup-ocamlopt.byte-build-env; + ocamlopt.byte; (* Compiles the master *) + all_modules = "tscanf2_io.cmx tscanf2_worker.ml"; + program = "${test_build_directory}/worker.opt"; + ocamlopt.byte; (* Compiles the worker *) + check-ocamlopt.byte-output; + program = "${test_build_directory}/master.opt"; + arguments = "${test_build_directory}/worker.opt"; + run; + check-program-output; + } *) (* A very simple master: diff --git a/testsuite/tests/lib-scanf/tscanf.ml b/testsuite/tests/lib-scanf/tscanf.ml index e9be7179c1..b79aab37cf 100644 --- a/testsuite/tests/lib-scanf/tscanf.ml +++ b/testsuite/tests/lib-scanf/tscanf.ml @@ -1,5 +1,5 @@ (* TEST - include testing + include testing; *) (* diff --git a/testsuite/tests/lib-seq/test.ml b/testsuite/tests/lib-seq/test.ml index 31913dc419..2936213c72 100644 --- a/testsuite/tests/lib-seq/test.ml +++ b/testsuite/tests/lib-seq/test.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) let (!?) = List.to_seq let (!!) = List.of_seq diff --git a/testsuite/tests/lib-set/testmap.ml b/testsuite/tests/lib-set/testmap.ml index b41c020df0..354567089f 100644 --- a/testsuite/tests/lib-set/testmap.ml +++ b/testsuite/tests/lib-set/testmap.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) module M = Map.Make(struct type t = int let compare (x:t) y = compare x y end) diff --git a/testsuite/tests/lib-set/testset.ml b/testsuite/tests/lib-set/testset.ml index 764987c00c..2d1bdb7e36 100644 --- a/testsuite/tests/lib-set/testset.ml +++ b/testsuite/tests/lib-set/testset.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) module S = Set.Make(struct type t = int let compare (x:t) y = compare x y end) diff --git a/testsuite/tests/lib-stack/test.ml b/testsuite/tests/lib-stack/test.ml index 16544f3fb6..e772d546c9 100644 --- a/testsuite/tests/lib-stack/test.ml +++ b/testsuite/tests/lib-stack/test.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) module S = struct include Stack diff --git a/testsuite/tests/lib-stdlabels/test_stdlabels.ml b/testsuite/tests/lib-stdlabels/test_stdlabels.ml index c846bcb7be..e7c8ebc9db 100644 --- a/testsuite/tests/lib-stdlabels/test_stdlabels.ml +++ b/testsuite/tests/lib-stdlabels/test_stdlabels.ml @@ -1,5 +1,5 @@ (* TEST - flags += " -nolabels " + flags += " -nolabels "; *) module A : module type of Array = ArrayLabels diff --git a/testsuite/tests/lib-str/parallel.ml b/testsuite/tests/lib-str/parallel.ml index 23f2a5f7de..8c027e3636 100644 --- a/testsuite/tests/lib-str/parallel.ml +++ b/testsuite/tests/lib-str/parallel.ml @@ -1,8 +1,11 @@ (* TEST -* hasstr -include str -** bytecode -** native + include str; + hasstr; + { + bytecode; + }{ + native; + } *) let total = Atomic.make 0 diff --git a/testsuite/tests/lib-str/t01.ml b/testsuite/tests/lib-str/t01.ml index 076172bdcb..ec8590157f 100644 --- a/testsuite/tests/lib-str/t01.ml +++ b/testsuite/tests/lib-str/t01.ml @@ -1,8 +1,11 @@ (* TEST -* hasstr -include str -** bytecode -** native + include str; + hasstr; + { + bytecode; + }{ + native; + } *) open Printf diff --git a/testsuite/tests/lib-string/binary.ml b/testsuite/tests/lib-string/binary.ml index 86f038d2da..c67656c5d1 100644 --- a/testsuite/tests/lib-string/binary.ml +++ b/testsuite/tests/lib-string/binary.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) let err x = match Lazy.force x with diff --git a/testsuite/tests/lib-string/test_string.ml b/testsuite/tests/lib-string/test_string.ml index 5a6f832643..3a2731329b 100644 --- a/testsuite/tests/lib-string/test_string.ml +++ b/testsuite/tests/lib-string/test_string.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) open Printf let rec build_string f n accu = diff --git a/testsuite/tests/lib-sync/prodcons.ml b/testsuite/tests/lib-sync/prodcons.ml index 2e2c09756c..34e5612fda 100644 --- a/testsuite/tests/lib-sync/prodcons.ml +++ b/testsuite/tests/lib-sync/prodcons.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) (* Classic producer-consumer *) diff --git a/testsuite/tests/lib-sync/trylock.ml b/testsuite/tests/lib-sync/trylock.ml index 314f1142ca..56b4691346 100644 --- a/testsuite/tests/lib-sync/trylock.ml +++ b/testsuite/tests/lib-sync/trylock.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) (* Test Mutex.try_lock *) diff --git a/testsuite/tests/lib-sync/trylock2.ml b/testsuite/tests/lib-sync/trylock2.ml index b31ace08b5..5cd8bdea60 100644 --- a/testsuite/tests/lib-sync/trylock2.ml +++ b/testsuite/tests/lib-sync/trylock2.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) (* Test Mutex.try_lock *) diff --git a/testsuite/tests/lib-sys/immediate64.ml b/testsuite/tests/lib-sys/immediate64.ml index 0f7dea7c42..84f73f6748 100644 --- a/testsuite/tests/lib-sys/immediate64.ml +++ b/testsuite/tests/lib-sys/immediate64.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) module M : sig type t [@@immediate64] diff --git a/testsuite/tests/lib-sys/rename.ml b/testsuite/tests/lib-sys/rename.ml index 2eb3935740..948481c3de 100644 --- a/testsuite/tests/lib-sys/rename.ml +++ b/testsuite/tests/lib-sys/rename.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) (* Test the Sys.rename function *) diff --git a/testsuite/tests/lib-systhreads/boundscheck.ml b/testsuite/tests/lib-systhreads/boundscheck.ml index 216dcebae7..254b89ba08 100644 --- a/testsuite/tests/lib-systhreads/boundscheck.ml +++ b/testsuite/tests/lib-systhreads/boundscheck.ml @@ -1,10 +1,11 @@ (* TEST - -include systhreads -* hassysthreads -** bytecode -** native - + include systhreads; + hassysthreads; + { + bytecode; + }{ + native; + } *) diff --git a/testsuite/tests/lib-systhreads/eintr.ml b/testsuite/tests/lib-systhreads/eintr.ml index 5c0a4d045e..56b7b857d3 100644 --- a/testsuite/tests/lib-systhreads/eintr.ml +++ b/testsuite/tests/lib-systhreads/eintr.ml @@ -1,10 +1,12 @@ (* TEST - -* hassysthreads -include systhreads -** not-windows -*** bytecode -*** native + include systhreads; + hassysthreads; + not-windows; + { + bytecode; + }{ + native; + } *) let signals_requested = Atomic.make 0 diff --git a/testsuite/tests/lib-systhreads/multicore_lifecycle.ml b/testsuite/tests/lib-systhreads/multicore_lifecycle.ml index f481464906..7a8e019024 100644 --- a/testsuite/tests/lib-systhreads/multicore_lifecycle.ml +++ b/testsuite/tests/lib-systhreads/multicore_lifecycle.ml @@ -1,8 +1,11 @@ (* TEST -* hassysthreads -include systhreads -** bytecode -** native + include systhreads; + hassysthreads; + { + bytecode; + }{ + native; + } *) let _ = diff --git a/testsuite/tests/lib-systhreads/test_c_thread_register.ml b/testsuite/tests/lib-systhreads/test_c_thread_register.ml index a8ec98aa9a..c18e49e4ca 100644 --- a/testsuite/tests/lib-systhreads/test_c_thread_register.ml +++ b/testsuite/tests/lib-systhreads/test_c_thread_register.ml @@ -1,10 +1,13 @@ (* TEST - modules = "test_c_thread_register_cstubs.c" - * hassysthreads - include systhreads - ** not-bsd - *** bytecode - *** native + modules = "test_c_thread_register_cstubs.c"; + include systhreads; + hassysthreads; + not-bsd; + { + bytecode; + }{ + native; + } *) (* spins a external thread from C and register it to the OCaml runtime *) diff --git a/testsuite/tests/lib-systhreads/testfork.ml b/testsuite/tests/lib-systhreads/testfork.ml index 3fdf386086..71d0cd5783 100644 --- a/testsuite/tests/lib-systhreads/testfork.ml +++ b/testsuite/tests/lib-systhreads/testfork.ml @@ -1,10 +1,13 @@ (* TEST - * hassysthreads - include systhreads - ** not-bsd - *** libunix - **** bytecode - **** native + include systhreads; + hassysthreads; + not-bsd; + libunix; + { + bytecode; + }{ + native; + } *) (* POSIX threads and fork() *) diff --git a/testsuite/tests/lib-systhreads/testfork2.ml b/testsuite/tests/lib-systhreads/testfork2.ml index 9f95024eee..bea41022d4 100644 --- a/testsuite/tests/lib-systhreads/testfork2.ml +++ b/testsuite/tests/lib-systhreads/testfork2.ml @@ -1,10 +1,13 @@ (* TEST - * hassysthreads - include systhreads - ** not-bsd - *** libunix - **** bytecode - **** native + include systhreads; + hassysthreads; + not-bsd; + libunix; + { + bytecode; + }{ + native; + } *) (* POSIX threads and fork() *) diff --git a/testsuite/tests/lib-systhreads/testpreempt.ml b/testsuite/tests/lib-systhreads/testpreempt.ml index 11d69152d6..5b30ea94d1 100644 --- a/testsuite/tests/lib-systhreads/testpreempt.ml +++ b/testsuite/tests/lib-systhreads/testpreempt.ml @@ -1,14 +1,17 @@ (* TEST - * hassysthreads + include systhreads; + hassysthreads; (* On Windows, we use Sleep(0) for triggering preemption of threads. However, this does not seem very reliable, so that this test fails on some Windows configurations. See GPR #1533. *) - include systhreads - ** not-windows - *** bytecode - *** native + not-windows; + { + bytecode; + }{ + native; + } *) let rec generate_list n = diff --git a/testsuite/tests/lib-systhreads/testyield.ml b/testsuite/tests/lib-systhreads/testyield.ml index 646dfe3e6f..29758cac0d 100644 --- a/testsuite/tests/lib-systhreads/testyield.ml +++ b/testsuite/tests/lib-systhreads/testyield.ml @@ -1,12 +1,16 @@ (* TEST + include systhreads; + hassysthreads; + not-windows; + { + bytecode; + }{ + native; + } +*) + (* Test that yielding between busy threads reliably triggers a thread switch. *) - * hassysthreads - include systhreads - ** not-windows - *** bytecode - *** native -*) let threads = 4 diff --git a/testsuite/tests/lib-systhreads/threadsigmask.ml b/testsuite/tests/lib-systhreads/threadsigmask.ml index 0e118413cb..9b84ffa879 100644 --- a/testsuite/tests/lib-systhreads/threadsigmask.ml +++ b/testsuite/tests/lib-systhreads/threadsigmask.ml @@ -1,10 +1,12 @@ (* TEST - -* hassysthreads -include systhreads -** not-windows -*** bytecode -*** native + include systhreads; + hassysthreads; + not-windows; + { + bytecode; + }{ + native; + } *) let stopped = ref false diff --git a/testsuite/tests/lib-threads/backtrace_threads.ml b/testsuite/tests/lib-threads/backtrace_threads.ml index 3c112d610e..5981c7cb96 100644 --- a/testsuite/tests/lib-threads/backtrace_threads.ml +++ b/testsuite/tests/lib-threads/backtrace_threads.ml @@ -1,10 +1,11 @@ (* TEST - -* hassysthreads -include systhreads -** bytecode -** native - + include systhreads; + hassysthreads; + { + bytecode; + }{ + native; + } *) let () = Printexc.record_backtrace true diff --git a/testsuite/tests/lib-threads/bank.ml b/testsuite/tests/lib-threads/bank.ml index 0f080ad3e1..e0302ab27e 100644 --- a/testsuite/tests/lib-threads/bank.ml +++ b/testsuite/tests/lib-threads/bank.ml @@ -1,10 +1,11 @@ (* TEST - -* hassysthreads -include systhreads -** bytecode -** native - + include systhreads; + hassysthreads; + { + bytecode; + }{ + native; + } *) (* The bank account example, using events and channels *) diff --git a/testsuite/tests/lib-threads/beat.ml b/testsuite/tests/lib-threads/beat.ml index 06120ab961..f4655ccb8d 100644 --- a/testsuite/tests/lib-threads/beat.ml +++ b/testsuite/tests/lib-threads/beat.ml @@ -1,12 +1,16 @@ (* TEST - -* hassysthreads -include systhreads -* skip -reason = "off-by-one error on MacOS+Clang (#408)" -** bytecode -** native - + { + include systhreads; + hassysthreads; + }{ + reason = "off-by-one error on MacOS+Clang (#408)"; + skip; + { + bytecode; + }{ + native; + } + } *) (* Test Thread.delay and its scheduling *) diff --git a/testsuite/tests/lib-threads/bufchan.ml b/testsuite/tests/lib-threads/bufchan.ml index df5f3984d7..f188cac8fa 100644 --- a/testsuite/tests/lib-threads/bufchan.ml +++ b/testsuite/tests/lib-threads/bufchan.ml @@ -1,10 +1,11 @@ (* TEST - -* hassysthreads -include systhreads -** bytecode -** native - + include systhreads; + hassysthreads; + { + bytecode; + }{ + native; + } *) open Event diff --git a/testsuite/tests/lib-threads/close.ml b/testsuite/tests/lib-threads/close.ml index 10f553a6b3..92e252d9e6 100644 --- a/testsuite/tests/lib-threads/close.ml +++ b/testsuite/tests/lib-threads/close.ml @@ -1,10 +1,11 @@ (* TEST - -* hassysthreads -include systhreads -** bytecode -** native - + include systhreads; + hassysthreads; + { + bytecode; + }{ + native; + } *) let main () = diff --git a/testsuite/tests/lib-threads/delayintr.ml b/testsuite/tests/lib-threads/delayintr.ml index 5fcc20143c..924d3179c4 100644 --- a/testsuite/tests/lib-threads/delayintr.ml +++ b/testsuite/tests/lib-threads/delayintr.ml @@ -1,48 +1,33 @@ (* TEST - -* hassysthreads -include systhreads - -readonly_files = "sigint.c" - -** libunix (* excludes mingw32/64 and msvc32/64 *) - -*** setup-ocamlc.byte-build-env - -program = "${test_build_directory}/delayintr.byte" - -**** ocamlc.byte - -program = "sigint" -all_modules = "sigint.c" - -***** ocamlc.byte - -program = "${test_build_directory}/delayintr.byte" -all_modules = "delayintr.ml" - -****** check-ocamlc.byte-output -******* run -******** check-program-output - -*** setup-ocamlopt.byte-build-env - -program = "${test_build_directory}/delayintr.opt" - -**** ocamlopt.byte - -program = "sigint" -all_modules = "sigint.c" - -***** ocamlopt.byte - -program = "${test_build_directory}/delayintr.opt" -all_modules = "delayintr.ml" - -****** check-ocamlopt.byte-output -******* run -******** check-program-output - + include systhreads; + readonly_files = "sigint.c"; + hassysthreads; + libunix; (* excludes mingw32/64 and msvc32/64 *) + { + program = "${test_build_directory}/delayintr.byte"; + setup-ocamlc.byte-build-env; + program = "sigint"; + all_modules = "sigint.c"; + ocamlc.byte; + program = "${test_build_directory}/delayintr.byte"; + all_modules = "delayintr.ml"; + ocamlc.byte; + check-ocamlc.byte-output; + run; + check-program-output; + }{ + program = "${test_build_directory}/delayintr.opt"; + setup-ocamlopt.byte-build-env; + program = "sigint"; + all_modules = "sigint.c"; + ocamlopt.byte; + program = "${test_build_directory}/delayintr.opt"; + all_modules = "delayintr.ml"; + ocamlopt.byte; + check-ocamlopt.byte-output; + run; + check-program-output; + } *) (* Regression test for MPR#7903 *) diff --git a/testsuite/tests/lib-threads/fileio.ml b/testsuite/tests/lib-threads/fileio.ml index 0e23128d1e..138be2bd1d 100644 --- a/testsuite/tests/lib-threads/fileio.ml +++ b/testsuite/tests/lib-threads/fileio.ml @@ -1,10 +1,11 @@ (* TEST - -* hassysthreads -include systhreads -** bytecode -** native - + include systhreads; + hassysthreads; + { + bytecode; + }{ + native; + } *) (* Test a file copy function *) diff --git a/testsuite/tests/lib-threads/mutex_errors.ml b/testsuite/tests/lib-threads/mutex_errors.ml index 25d3330955..1cbd6aaf8c 100644 --- a/testsuite/tests/lib-threads/mutex_errors.ml +++ b/testsuite/tests/lib-threads/mutex_errors.ml @@ -1,10 +1,11 @@ (* TEST - -* hassysthreads -include systhreads -** bytecode -** native - + include systhreads; + hassysthreads; + { + bytecode; + }{ + native; + } *) let log s = diff --git a/testsuite/tests/lib-threads/pr4466.ml b/testsuite/tests/lib-threads/pr4466.ml index 8b53539ded..1e0e36a72c 100644 --- a/testsuite/tests/lib-threads/pr4466.ml +++ b/testsuite/tests/lib-threads/pr4466.ml @@ -1,8 +1,7 @@ (* TEST - -* hassysthreads - include systhreads -** native + include systhreads; + hassysthreads; + native; *) open Printf diff --git a/testsuite/tests/lib-threads/pr5325.ml b/testsuite/tests/lib-threads/pr5325.ml index 9f27f038fd..873d569700 100644 --- a/testsuite/tests/lib-threads/pr5325.ml +++ b/testsuite/tests/lib-threads/pr5325.ml @@ -1,10 +1,11 @@ (* TEST - -* hassysthreads -include systhreads -** bytecode -** native - + include systhreads; + hassysthreads; + { + bytecode; + }{ + native; + } *) open Printf diff --git a/testsuite/tests/lib-threads/pr7638.ml b/testsuite/tests/lib-threads/pr7638.ml index ea7fabc530..83cd7cf814 100644 --- a/testsuite/tests/lib-threads/pr7638.ml +++ b/testsuite/tests/lib-threads/pr7638.ml @@ -1,12 +1,12 @@ (* TEST - -unset DOES_NOT_EXIST - -* hassysthreads -include systhreads -** bytecode -** native - + unset DOES_NOT_EXIST; + include systhreads; + hassysthreads; + { + bytecode; + }{ + native; + } *) (* MPR#7638 repro case *) diff --git a/testsuite/tests/lib-threads/pr8857.ml b/testsuite/tests/lib-threads/pr8857.ml index cc6d53d4c5..1d14b12cae 100644 --- a/testsuite/tests/lib-threads/pr8857.ml +++ b/testsuite/tests/lib-threads/pr8857.ml @@ -1,10 +1,11 @@ (* TEST - -* hassysthreads -include systhreads -** bytecode -** native - + include systhreads; + hassysthreads; + { + bytecode; + }{ + native; + } *) let _ = diff --git a/testsuite/tests/lib-threads/prodcons.ml b/testsuite/tests/lib-threads/prodcons.ml index 4867ed38d1..8c27984127 100644 --- a/testsuite/tests/lib-threads/prodcons.ml +++ b/testsuite/tests/lib-threads/prodcons.ml @@ -1,10 +1,11 @@ (* TEST - -* hassysthreads -include systhreads -** bytecode -** native - + include systhreads; + hassysthreads; + { + bytecode; + }{ + native; + } *) (* Classic producer-consumer *) diff --git a/testsuite/tests/lib-threads/prodcons2.ml b/testsuite/tests/lib-threads/prodcons2.ml index 308fcd5151..3fe057c397 100644 --- a/testsuite/tests/lib-threads/prodcons2.ml +++ b/testsuite/tests/lib-threads/prodcons2.ml @@ -1,10 +1,11 @@ (* TEST - -* hassysthreads -include systhreads -** bytecode -** native - + include systhreads; + hassysthreads; + { + bytecode; + }{ + native; + } *) (* Producer-consumer with events and multiple producers *) diff --git a/testsuite/tests/lib-threads/sieve.ml b/testsuite/tests/lib-threads/sieve.ml index d4cdd447e1..3f8769ff8a 100644 --- a/testsuite/tests/lib-threads/sieve.ml +++ b/testsuite/tests/lib-threads/sieve.ml @@ -1,17 +1,17 @@ (* TEST - -script = "sh ${test_source_directory}/test-runtime-cleanup.sh" - -* hassysthreads -include systhreads -** script -*** bytecode -output = "${test_build_directory}/program-output" -stdout = "${output}" -*** native -output = "${test_build_directory}/program-output" -stdout = "${output}" - + script = "sh ${test_source_directory}/test-runtime-cleanup.sh"; + include systhreads; + hassysthreads; + script; + { + output = "${test_build_directory}/program-output"; + stdout = "${output}"; + bytecode; + }{ + output = "${test_build_directory}/program-output"; + stdout = "${output}"; + native; + } *) (* This test is skipped in "runtime cleanup at exit" mode diff --git a/testsuite/tests/lib-threads/signal.ml b/testsuite/tests/lib-threads/signal.ml index bfc1ea8c30..9073247959 100644 --- a/testsuite/tests/lib-threads/signal.ml +++ b/testsuite/tests/lib-threads/signal.ml @@ -1,48 +1,33 @@ (* TEST - -* hassysthreads -include systhreads - -readonly_files = "sigint.c" - -** libunix (* excludes mingw32/64 and msvc32/64 *) - -*** setup-ocamlc.byte-build-env - -program = "${test_build_directory}/signal.byte" - -**** ocamlc.byte - -program = "sigint" -all_modules = "sigint.c" - -***** ocamlc.byte - -program = "${test_build_directory}/signal.byte" -all_modules = "signal.ml" - -****** check-ocamlc.byte-output -******* run -******** check-program-output - -*** setup-ocamlopt.byte-build-env - -program = "${test_build_directory}/signal.opt" - -**** ocamlopt.byte - -program = "sigint" -all_modules = "sigint.c" - -***** ocamlopt.byte - -program = "${test_build_directory}/signal.opt" -all_modules = "signal.ml" - -****** check-ocamlopt.byte-output -******* run -******** check-program-output - + include systhreads; + readonly_files = "sigint.c"; + hassysthreads; + libunix; (* excludes mingw32/64 and msvc32/64 *) + { + program = "${test_build_directory}/signal.byte"; + setup-ocamlc.byte-build-env; + program = "sigint"; + all_modules = "sigint.c"; + ocamlc.byte; + program = "${test_build_directory}/signal.byte"; + all_modules = "signal.ml"; + ocamlc.byte; + check-ocamlc.byte-output; + run; + check-program-output; + }{ + program = "${test_build_directory}/signal.opt"; + setup-ocamlopt.byte-build-env; + program = "sigint"; + all_modules = "sigint.c"; + ocamlopt.byte; + program = "${test_build_directory}/signal.opt"; + all_modules = "signal.ml"; + ocamlopt.byte; + check-ocamlopt.byte-output; + run; + check-program-output; + } *) let signaled = ref false diff --git a/testsuite/tests/lib-threads/sockets.ml b/testsuite/tests/lib-threads/sockets.ml index c7299c42e7..91e67f7185 100644 --- a/testsuite/tests/lib-threads/sockets.ml +++ b/testsuite/tests/lib-threads/sockets.ml @@ -1,12 +1,12 @@ (* TEST - -* hassysthreads -include systhreads - -** libunix (* Broken on Windows (missing join?), needs to be fixed *) -*** bytecode -*** native - + include systhreads; + hassysthreads; + libunix; (* Broken on Windows (missing join?), needs to be fixed *) + { + bytecode; + }{ + native; + } *) open Printf diff --git a/testsuite/tests/lib-threads/swapchan.ml b/testsuite/tests/lib-threads/swapchan.ml index 3536b82e2e..6c9c3d7714 100644 --- a/testsuite/tests/lib-threads/swapchan.ml +++ b/testsuite/tests/lib-threads/swapchan.ml @@ -1,10 +1,11 @@ (* TEST - -* hassysthreads -include systhreads -** bytecode -** native - + include systhreads; + hassysthreads; + { + bytecode; + }{ + native; + } *) open Event diff --git a/testsuite/tests/lib-threads/tls.ml b/testsuite/tests/lib-threads/tls.ml index 2741f7ef0b..0aa52792eb 100644 --- a/testsuite/tests/lib-threads/tls.ml +++ b/testsuite/tests/lib-threads/tls.ml @@ -1,10 +1,11 @@ (* TEST - -* hassysthreads -include systhreads -** bytecode -** native - + include systhreads; + hassysthreads; + { + bytecode; + }{ + native; + } *) let private_data = (Hashtbl.create 17 : (Thread.t, string) Hashtbl.t) diff --git a/testsuite/tests/lib-threads/torture.ml b/testsuite/tests/lib-threads/torture.ml index 16a7811d40..0a5671b0f6 100644 --- a/testsuite/tests/lib-threads/torture.ml +++ b/testsuite/tests/lib-threads/torture.ml @@ -1,10 +1,11 @@ (* TEST - -* hassysthreads -include systhreads -** bytecode -** native - + include systhreads; + hassysthreads; + { + bytecode; + }{ + native; + } *) (* Torture test - I/O interspersed with lots of GC *) diff --git a/testsuite/tests/lib-threads/uncaught_exception_handler.ml b/testsuite/tests/lib-threads/uncaught_exception_handler.ml index 06cf8f60f0..04de48b589 100644 --- a/testsuite/tests/lib-threads/uncaught_exception_handler.ml +++ b/testsuite/tests/lib-threads/uncaught_exception_handler.ml @@ -1,12 +1,12 @@ -(* TEST +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + + -flags = "-g" -ocamlrunparam += ",b=1" -* hassysthreads -include systhreads -** bytecode -** native *) @@ -38,3 +38,15 @@ let _ = Thread.set_uncaught_exception_handler (handler Thread.Exit); let th = Thread.create fn () in Thread.join th + +(* TEST + flags = "-g"; + ocamlrunparam += ",b=1"; + include systhreads; + hassysthreads; + { + bytecode; + }{ + native; + } +*) diff --git a/testsuite/tests/lib-uchar/test.ml b/testsuite/tests/lib-uchar/test.ml index 14e907d230..bc7643fc3b 100644 --- a/testsuite/tests/lib-uchar/test.ml +++ b/testsuite/tests/lib-uchar/test.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) let assert_raise_invalid_argument f v = assert (try ignore (f v); false with Invalid_argument _ -> true) diff --git a/testsuite/tests/lib-unix/common/channel_of.ml b/testsuite/tests/lib-unix/common/channel_of.ml index fb9f294d61..bbb4c6ef17 100644 --- a/testsuite/tests/lib-unix/common/channel_of.ml +++ b/testsuite/tests/lib-unix/common/channel_of.ml @@ -1,8 +1,11 @@ (* TEST -* hasunix -include unix -** bytecode -** native + include unix; + hasunix; + { + bytecode; + }{ + native; + } *) open Printf diff --git a/testsuite/tests/lib-unix/common/cloexec.ml b/testsuite/tests/lib-unix/common/cloexec.ml index cb919eb564..9723a778e4 100644 --- a/testsuite/tests/lib-unix/common/cloexec.ml +++ b/testsuite/tests/lib-unix/common/cloexec.ml @@ -1,48 +1,47 @@ (* TEST + include unix; + readonly_files = "fdstatus_aux.c fdstatus_main.ml"; + (* + This test is temporarily disabled on the MinGW and MSVC ports, + because since fdstatus has been wrapped in an OCaml program, + it does not work as well as before. + Presumably this is because the OCaml runtime opens files, so that handles + that have actually been closed at execution look open and make the + test fail. -(* - This test is temporarily disabled on the MinGW and MSVC ports, - because since fdstatus has been wrapped in an OCaml program, - it does not work as well as before. - Presumably this is because the OCaml runtime opens files, so that handles - that have actually been closed at execution look open and make the - test fail. - - One possible fix for this would be to make it possible for ocamltest to - compile C-only programs, which will be a bit of work to handle the - output of msvc and will also duplicate what the OCaml compiler itself - already does. -*) - -* hasunix -include unix -readonly_files = "fdstatus_aux.c fdstatus_main.ml" - -** libunix -*** setup-ocamlc.byte-build-env -program = "${test_build_directory}/cloexec.byte" -**** ocamlc.byte -program = "${test_build_directory}/fdstatus.exe" -all_modules = "fdstatus_aux.c fdstatus_main.ml" -***** ocamlc.byte -program = "${test_build_directory}/cloexec.byte" -all_modules= "cloexec.ml" -****** check-ocamlc.byte-output -******* run -******** check-program-output - -*** setup-ocamlopt.byte-build-env -program = "${test_build_directory}/cloexec.opt" -**** ocamlopt.byte -program = "${test_build_directory}/fdstatus.exe" -all_modules = "fdstatus_aux.c fdstatus_main.ml" -***** ocamlopt.byte -program = "${test_build_directory}/cloexec.opt" -all_modules= "cloexec.ml" -****** check-ocamlopt.byte-output -******* run -******** check-program-output + One possible fix for this would be to make it possible for ocamltest to + compile C-only programs, which will be a bit of work to handle the + output of msvc and will also duplicate what the OCaml compiler itself + already does. + *) + hasunix; + libunix; + { + program = "${test_build_directory}/cloexec.byte"; + setup-ocamlc.byte-build-env; + program = "${test_build_directory}/fdstatus.exe"; + all_modules = "fdstatus_aux.c fdstatus_main.ml"; + ocamlc.byte; + program = "${test_build_directory}/cloexec.byte"; + all_modules = "cloexec.ml"; + ocamlc.byte; + check-ocamlc.byte-output; + run; + check-program-output; + }{ + program = "${test_build_directory}/cloexec.opt"; + setup-ocamlopt.byte-build-env; + program = "${test_build_directory}/fdstatus.exe"; + all_modules = "fdstatus_aux.c fdstatus_main.ml"; + ocamlopt.byte; + program = "${test_build_directory}/cloexec.opt"; + all_modules = "cloexec.ml"; + ocamlopt.byte; + check-ocamlopt.byte-output; + run; + check-program-output; + } *) (* This is a terrible hack that plays on the internal representation diff --git a/testsuite/tests/lib-unix/common/dup.ml b/testsuite/tests/lib-unix/common/dup.ml index b689137c0b..2ca20cba53 100644 --- a/testsuite/tests/lib-unix/common/dup.ml +++ b/testsuite/tests/lib-unix/common/dup.ml @@ -1,8 +1,11 @@ (* TEST -* hasunix -include unix -** bytecode -** native + include unix; + hasunix; + { + bytecode; + }{ + native; + } *) let _ = diff --git a/testsuite/tests/lib-unix/common/dup2.ml b/testsuite/tests/lib-unix/common/dup2.ml index c3a7faccda..84f3f92030 100644 --- a/testsuite/tests/lib-unix/common/dup2.ml +++ b/testsuite/tests/lib-unix/common/dup2.ml @@ -1,9 +1,12 @@ (* TEST -* hasunix -include unix -stderr = "/dev/null" -** bytecode -** native + include unix; + stderr = "/dev/null"; + hasunix; + { + bytecode; + }{ + native; + } *) let cat file = diff --git a/testsuite/tests/lib-unix/common/fork_cleanup.ml b/testsuite/tests/lib-unix/common/fork_cleanup.ml index eca8f9de9d..0206c01b03 100644 --- a/testsuite/tests/lib-unix/common/fork_cleanup.ml +++ b/testsuite/tests/lib-unix/common/fork_cleanup.ml @@ -1,9 +1,12 @@ (* TEST -* hasunix -include unix -** not-windows -*** bytecode -*** native + include unix; + hasunix; + not-windows; + { + bytecode; + }{ + native; + } *) (* this test checks that the domain lock is properly reinitialized diff --git a/testsuite/tests/lib-unix/common/fork_cleanup_systhreads.ml b/testsuite/tests/lib-unix/common/fork_cleanup_systhreads.ml index db0ebf4f6d..a25f217b97 100644 --- a/testsuite/tests/lib-unix/common/fork_cleanup_systhreads.ml +++ b/testsuite/tests/lib-unix/common/fork_cleanup_systhreads.ml @@ -1,9 +1,12 @@ (* TEST -* hassysthreads -include systhreads -** not-windows -*** bytecode -*** native + include systhreads; + hassysthreads; + not-windows; + { + bytecode; + }{ + native; + } *) (* this test checks that the domain lock is properly reinitialized diff --git a/testsuite/tests/lib-unix/common/getaddrinfo.ml b/testsuite/tests/lib-unix/common/getaddrinfo.ml index b140ef9143..4c5b88d51f 100644 --- a/testsuite/tests/lib-unix/common/getaddrinfo.ml +++ b/testsuite/tests/lib-unix/common/getaddrinfo.ml @@ -1,8 +1,11 @@ (* TEST -* hasunix -include unix -** bytecode -** native + include unix; + hasunix; + { + bytecode; + }{ + native; + } *) let () = diff --git a/testsuite/tests/lib-unix/common/gethostbyaddr.ml b/testsuite/tests/lib-unix/common/gethostbyaddr.ml index a8ea1cf8d4..e9d4b53a5c 100644 --- a/testsuite/tests/lib-unix/common/gethostbyaddr.ml +++ b/testsuite/tests/lib-unix/common/gethostbyaddr.ml @@ -1,8 +1,11 @@ (* TEST -* hasunix -include unix -** bytecode -** native + include unix; + hasunix; + { + bytecode; + }{ + native; + } *) (* Checks that gethostbyaddr supports both IPv4 and IPv6 (see #11461) *) diff --git a/testsuite/tests/lib-unix/common/multicore_fork_domain_alone.ml b/testsuite/tests/lib-unix/common/multicore_fork_domain_alone.ml index 077a3dba66..1f0f57a183 100644 --- a/testsuite/tests/lib-unix/common/multicore_fork_domain_alone.ml +++ b/testsuite/tests/lib-unix/common/multicore_fork_domain_alone.ml @@ -1,9 +1,12 @@ (* TEST -include unix -* hasunix -** not-windows -*** bytecode -*** native + include unix; + hasunix; + not-windows; + { + bytecode; + }{ + native; + } *) (* on Multicore, fork is not allowed is another domain is, and was running. *) diff --git a/testsuite/tests/lib-unix/common/multicore_fork_domain_alone2.ml b/testsuite/tests/lib-unix/common/multicore_fork_domain_alone2.ml index 929ed5ecf7..79b9d6c253 100644 --- a/testsuite/tests/lib-unix/common/multicore_fork_domain_alone2.ml +++ b/testsuite/tests/lib-unix/common/multicore_fork_domain_alone2.ml @@ -1,9 +1,12 @@ (* TEST -include unix -* hasunix -** not-windows -*** bytecode -*** native + include unix; + hasunix; + not-windows; + { + bytecode; + }{ + native; + } *) (* on Multicore, fork is not allowed is another domain is, and was running. *) diff --git a/testsuite/tests/lib-unix/common/pipe_eof.ml b/testsuite/tests/lib-unix/common/pipe_eof.ml index 3bd6ae5f1a..415107da05 100644 --- a/testsuite/tests/lib-unix/common/pipe_eof.ml +++ b/testsuite/tests/lib-unix/common/pipe_eof.ml @@ -1,8 +1,11 @@ (* TEST -* hasunix -include unix -** bytecode -** native + include unix; + hasunix; + { + bytecode; + }{ + native; + } *) let drain pipe = diff --git a/testsuite/tests/lib-unix/common/process_pid.ml b/testsuite/tests/lib-unix/common/process_pid.ml index 8d8852f6d4..f2c25f4666 100644 --- a/testsuite/tests/lib-unix/common/process_pid.ml +++ b/testsuite/tests/lib-unix/common/process_pid.ml @@ -1,8 +1,11 @@ (* TEST -* hasunix -include unix -** bytecode -** native + include unix; + hasunix; + { + bytecode; + }{ + native; + } *) let () = diff --git a/testsuite/tests/lib-unix/common/redirections.ml b/testsuite/tests/lib-unix/common/redirections.ml index b9c04a2323..fb008a3826 100644 --- a/testsuite/tests/lib-unix/common/redirections.ml +++ b/testsuite/tests/lib-unix/common/redirections.ml @@ -1,35 +1,34 @@ (* TEST - -readonly_files = "reflector.ml" -unset XVAR - -* hasunix -** setup-ocamlc.byte-build-env -program = "${test_build_directory}/redirections.byte" -*** ocamlc.byte -program = "${test_build_directory}/reflector.exe" -all_modules = "reflector.ml" -**** ocamlc.byte -include unix -program = "${test_build_directory}/redirections.byte" -all_modules= "redirections.ml" -***** check-ocamlc.byte-output -****** run -******* check-program-output - -** setup-ocamlopt.byte-build-env -program = "${test_build_directory}/redirections.opt" -*** ocamlopt.byte -program = "${test_build_directory}/reflector.exe" -all_modules = "reflector.ml" -**** ocamlopt.byte -include unix -program = "${test_build_directory}/redirections.opt" -all_modules= "redirections.ml" -***** check-ocamlopt.byte-output -****** run -******* check-program-output - + readonly_files = "reflector.ml"; + unset XVAR; + hasunix; + { + program = "${test_build_directory}/redirections.byte"; + setup-ocamlc.byte-build-env; + program = "${test_build_directory}/reflector.exe"; + all_modules = "reflector.ml"; + ocamlc.byte; + include unix; + program = "${test_build_directory}/redirections.byte"; + all_modules = "redirections.ml"; + ocamlc.byte; + check-ocamlc.byte-output; + run; + check-program-output; + }{ + program = "${test_build_directory}/redirections.opt"; + setup-ocamlopt.byte-build-env; + program = "${test_build_directory}/reflector.exe"; + all_modules = "reflector.ml"; + ocamlopt.byte; + include unix; + program = "${test_build_directory}/redirections.opt"; + all_modules = "redirections.ml"; + ocamlopt.byte; + check-ocamlopt.byte-output; + run; + check-program-output; + } *) diff --git a/testsuite/tests/lib-unix/common/rename.ml b/testsuite/tests/lib-unix/common/rename.ml index 402ddf0bd3..4a88eaa3f0 100644 --- a/testsuite/tests/lib-unix/common/rename.ml +++ b/testsuite/tests/lib-unix/common/rename.ml @@ -1,8 +1,11 @@ (* TEST -* hasunix -include unix -** bytecode -** native + include unix; + hasunix; + { + bytecode; + }{ + native; + } *) (* Test the Unix.rename function *) diff --git a/testsuite/tests/lib-unix/common/test_unix_cmdline.ml b/testsuite/tests/lib-unix/common/test_unix_cmdline.ml index 08af41e29a..aff235bd3f 100644 --- a/testsuite/tests/lib-unix/common/test_unix_cmdline.ml +++ b/testsuite/tests/lib-unix/common/test_unix_cmdline.ml @@ -1,34 +1,33 @@ (* TEST - -readonly_files = "cmdline_prog.ml" - -* hasunix -** setup-ocamlc.byte-build-env -program = "${test_build_directory}/test_unix_cmdline.byte" -*** ocamlc.byte -program = "${test_build_directory}/cmdline_prog.exe" -all_modules = "cmdline_prog.ml" -**** ocamlc.byte -include unix -program = "${test_build_directory}/test_unix_cmdline.byte" -all_modules= "test_unix_cmdline.ml" -***** check-ocamlc.byte-output -****** run -******* check-program-output - -** setup-ocamlopt.byte-build-env -program = "${test_build_directory}/test_unix_cmdline.opt" -*** ocamlc.byte -program = "${test_build_directory}/cmdline_prog.exe" -all_modules = "cmdline_prog.ml" -**** ocamlopt.byte -include unix -program = "${test_build_directory}/test_unix_cmdline.opt" -all_modules= "test_unix_cmdline.ml" -***** check-ocamlopt.byte-output -****** run -******* check-program-output - + readonly_files = "cmdline_prog.ml"; + hasunix; + { + program = "${test_build_directory}/test_unix_cmdline.byte"; + setup-ocamlc.byte-build-env; + program = "${test_build_directory}/cmdline_prog.exe"; + all_modules = "cmdline_prog.ml"; + ocamlc.byte; + include unix; + program = "${test_build_directory}/test_unix_cmdline.byte"; + all_modules = "test_unix_cmdline.ml"; + ocamlc.byte; + check-ocamlc.byte-output; + run; + check-program-output; + }{ + program = "${test_build_directory}/test_unix_cmdline.opt"; + setup-ocamlopt.byte-build-env; + program = "${test_build_directory}/cmdline_prog.exe"; + all_modules = "cmdline_prog.ml"; + ocamlc.byte; + include unix; + program = "${test_build_directory}/test_unix_cmdline.opt"; + all_modules = "test_unix_cmdline.ml"; + ocamlopt.byte; + check-ocamlopt.byte-output; + run; + check-program-output; + } *) let prog_name = "cmdline_prog.exe" diff --git a/testsuite/tests/lib-unix/common/test_unixlabels.ml b/testsuite/tests/lib-unix/common/test_unixlabels.ml index fc0335b5f8..c34196fbc0 100644 --- a/testsuite/tests/lib-unix/common/test_unixlabels.ml +++ b/testsuite/tests/lib-unix/common/test_unixlabels.ml @@ -1,9 +1,12 @@ (* TEST -include unix -flags += " -nolabels " -* hasunix -** bytecode -** native + include unix; + flags += " -nolabels "; + hasunix; + { + bytecode; + }{ + native; + } *) module U : module type of Unix = UnixLabels diff --git a/testsuite/tests/lib-unix/common/truncate.ml b/testsuite/tests/lib-unix/common/truncate.ml index a91cabcbb1..50998367d8 100644 --- a/testsuite/tests/lib-unix/common/truncate.ml +++ b/testsuite/tests/lib-unix/common/truncate.ml @@ -1,8 +1,11 @@ (* TEST -include unix -* hasunix -** bytecode -** native + include unix; + hasunix; + { + bytecode; + }{ + native; + } *) let str = "Hello, OCaml!" diff --git a/testsuite/tests/lib-unix/common/uexit.ml b/testsuite/tests/lib-unix/common/uexit.ml index b80f32087c..50ec1aa9ca 100644 --- a/testsuite/tests/lib-unix/common/uexit.ml +++ b/testsuite/tests/lib-unix/common/uexit.ml @@ -1,8 +1,11 @@ (* TEST -* hasunix -include unix -** bytecode -** native + include unix; + hasunix; + { + bytecode; + }{ + native; + } *) let _ = diff --git a/testsuite/tests/lib-unix/common/utimes.ml b/testsuite/tests/lib-unix/common/utimes.ml index 58aecb6ed2..644579e262 100644 --- a/testsuite/tests/lib-unix/common/utimes.ml +++ b/testsuite/tests/lib-unix/common/utimes.ml @@ -1,9 +1,12 @@ (* TEST -* hasunix -include unix -readonly_files = "utimes.txt" -** bytecode -** native + include unix; + readonly_files = "utimes.txt"; + hasunix; + { + bytecode; + }{ + native; + } *) (* We do not check setting the "last access time" because it is hard to do so on diff --git a/testsuite/tests/lib-unix/common/wait_nohang.ml b/testsuite/tests/lib-unix/common/wait_nohang.ml index fb4c0b259e..bddd61a507 100644 --- a/testsuite/tests/lib-unix/common/wait_nohang.ml +++ b/testsuite/tests/lib-unix/common/wait_nohang.ml @@ -1,34 +1,33 @@ (* TEST - -readonly_files = "reflector.ml" - -* hasunix -** setup-ocamlc.byte-build-env -program = "${test_build_directory}/wait_nohang.byte" -*** ocamlc.byte -program = "${test_build_directory}/reflector.exe" -all_modules = "reflector.ml" -**** ocamlc.byte -include unix -program = "${test_build_directory}/wait_nohang.byte" -all_modules= "wait_nohang.ml" -***** check-ocamlc.byte-output -****** run -******* check-program-output - -** setup-ocamlopt.byte-build-env -program = "${test_build_directory}/wait_nohang.opt" -*** ocamlopt.byte -program = "${test_build_directory}/reflector.exe" -all_modules = "reflector.ml" -**** ocamlopt.byte -include unix -program = "${test_build_directory}/wait_nohang.opt" -all_modules= "wait_nohang.ml" -***** check-ocamlopt.byte-output -****** run -******* check-program-output - + readonly_files = "reflector.ml"; + hasunix; + { + program = "${test_build_directory}/wait_nohang.byte"; + setup-ocamlc.byte-build-env; + program = "${test_build_directory}/reflector.exe"; + all_modules = "reflector.ml"; + ocamlc.byte; + include unix; + program = "${test_build_directory}/wait_nohang.byte"; + all_modules = "wait_nohang.ml"; + ocamlc.byte; + check-ocamlc.byte-output; + run; + check-program-output; + }{ + program = "${test_build_directory}/wait_nohang.opt"; + setup-ocamlopt.byte-build-env; + program = "${test_build_directory}/reflector.exe"; + all_modules = "reflector.ml"; + ocamlopt.byte; + include unix; + program = "${test_build_directory}/wait_nohang.opt"; + all_modules = "wait_nohang.ml"; + ocamlopt.byte; + check-ocamlopt.byte-output; + run; + check-program-output; + } *) let refl = diff --git a/testsuite/tests/lib-unix/isatty/isatty_std.ml b/testsuite/tests/lib-unix/isatty/isatty_std.ml index 1dcff45317..3ce2759300 100644 --- a/testsuite/tests/lib-unix/isatty/isatty_std.ml +++ b/testsuite/tests/lib-unix/isatty/isatty_std.ml @@ -1,10 +1,13 @@ (* TEST -* hasunix -include unix -stdin = "/dev/null" -stderr = "/dev/null" -** bytecode -** native + include unix; + stdin = "/dev/null"; + stderr = "/dev/null"; + hasunix; + { + bytecode; + }{ + native; + } *) Printf.printf diff --git a/testsuite/tests/lib-unix/isatty/isatty_tty.ml b/testsuite/tests/lib-unix/isatty/isatty_tty.ml index df57e7a3ec..aeed2f781f 100644 --- a/testsuite/tests/lib-unix/isatty/isatty_tty.ml +++ b/testsuite/tests/lib-unix/isatty/isatty_tty.ml @@ -1,10 +1,11 @@ (* TEST - -* libwin32unix -include unix -** bytecode -** native - + include unix; + libwin32unix; + { + bytecode; + }{ + native; + } *) let console = diff --git a/testsuite/tests/lib-unix/kill/unix_kill.ml b/testsuite/tests/lib-unix/kill/unix_kill.ml index 2ace3849c3..a58fedacd3 100644 --- a/testsuite/tests/lib-unix/kill/unix_kill.ml +++ b/testsuite/tests/lib-unix/kill/unix_kill.ml @@ -1,8 +1,11 @@ (* TEST -include unix -* libunix -** bytecode -** native + include unix; + libunix; + { + bytecode; + }{ + native; + } *) let () = diff --git a/testsuite/tests/lib-unix/realpath/test.ml b/testsuite/tests/lib-unix/realpath/test.ml index 422c718b49..4ec43cc88d 100644 --- a/testsuite/tests/lib-unix/realpath/test.ml +++ b/testsuite/tests/lib-unix/realpath/test.ml @@ -1,8 +1,11 @@ (* TEST -* hasunix -include unix -** bytecode -** native + include unix; + hasunix; + { + bytecode; + }{ + native; + } *) let main () = diff --git a/testsuite/tests/lib-unix/unix-execvpe/exec.ml b/testsuite/tests/lib-unix/unix-execvpe/exec.ml index 70923d5446..06ec0924cd 100644 --- a/testsuite/tests/lib-unix/unix-execvpe/exec.ml +++ b/testsuite/tests/lib-unix/unix-execvpe/exec.ml @@ -1,11 +1,14 @@ (* TEST - unset FOO - * hasunix - include unix - script = "sh ${test_source_directory}/has-execvpe.sh" - ** script - *** bytecode - *** native + unset FOO; + include unix; + script = "sh ${test_source_directory}/has-execvpe.sh"; + hasunix; + script; + { + bytecode; + }{ + native; + } *) open Printf diff --git a/testsuite/tests/lib-unix/unix-socket/recvfrom_linux.ml b/testsuite/tests/lib-unix/unix-socket/recvfrom_linux.ml index 73fa3fb273..3eaef789e7 100644 --- a/testsuite/tests/lib-unix/unix-socket/recvfrom_linux.ml +++ b/testsuite/tests/lib-unix/unix-socket/recvfrom_linux.ml @@ -1,11 +1,14 @@ (* TEST -include unix -modules = "recvfrom.ml" -script = "sh ${test_source_directory}/is-linux.sh" -* hasunix -** script -*** bytecode -*** native + include unix; + modules = "recvfrom.ml"; + script = "sh ${test_source_directory}/is-linux.sh"; + hasunix; + script; + { + bytecode; + }{ + native; + } *) open Recvfrom diff --git a/testsuite/tests/lib-unix/unix-socket/recvfrom_unix.ml b/testsuite/tests/lib-unix/unix-socket/recvfrom_unix.ml index e584ff17a3..2e31d00df0 100644 --- a/testsuite/tests/lib-unix/unix-socket/recvfrom_unix.ml +++ b/testsuite/tests/lib-unix/unix-socket/recvfrom_unix.ml @@ -1,10 +1,13 @@ (* TEST -include unix -modules = "recvfrom.ml" -* hasunix -** not-windows -*** bytecode -*** native + include unix; + modules = "recvfrom.ml"; + hasunix; + not-windows; + { + bytecode; + }{ + native; + } *) open Recvfrom diff --git a/testsuite/tests/lib-unix/win-channel-of/parallel_channel_of.ml b/testsuite/tests/lib-unix/win-channel-of/parallel_channel_of.ml index 01ae4df1c3..4670a41071 100644 --- a/testsuite/tests/lib-unix/win-channel-of/parallel_channel_of.ml +++ b/testsuite/tests/lib-unix/win-channel-of/parallel_channel_of.ml @@ -1,9 +1,12 @@ (* TEST -modules = "fd_of_channel.c" -* libwin32unix -include unix -** bytecode -** native + modules = "fd_of_channel.c"; + include unix; + libwin32unix; + { + bytecode; + }{ + native; + } *) external fd_of_in_channel: in_channel -> int = "caml_fd_of_channel" diff --git a/testsuite/tests/lib-unix/win-createprocess/test.ml b/testsuite/tests/lib-unix/win-createprocess/test.ml index b72f68cf54..d648f284e2 100644 --- a/testsuite/tests/lib-unix/win-createprocess/test.ml +++ b/testsuite/tests/lib-unix/win-createprocess/test.ml @@ -1,10 +1,11 @@ (* TEST - -* libwin32unix - include unix -** bytecode -** native - + include unix; + libwin32unix; + { + bytecode; + }{ + native; + } *) (* This test is inspired by [Creating a Child Process with Redirected diff --git a/testsuite/tests/lib-unix/win-env/test_env.ml b/testsuite/tests/lib-unix/win-env/test_env.ml index 8f22c4a6f5..3b9ca9a494 100644 --- a/testsuite/tests/lib-unix/win-env/test_env.ml +++ b/testsuite/tests/lib-unix/win-env/test_env.ml @@ -1,12 +1,15 @@ (* TEST -unset FOO -unset FOO2 -include unix -flags += "-strict-sequence -w +A-70 -warn-error +A" -modules = "stubs.c" -* libwin32unix -** bytecode -** native + unset FOO; + unset FOO2; + include unix; + flags += "-strict-sequence -w +A-70 -warn-error +A"; + modules = "stubs.c"; + libwin32unix; + { + bytecode; + }{ + native; + } *) external set_environment_variable: string -> string -> unit diff --git a/testsuite/tests/lib-unix/win-socketpair/test.ml b/testsuite/tests/lib-unix/win-socketpair/test.ml index 8ea703e0c1..cecd4a54c9 100644 --- a/testsuite/tests/lib-unix/win-socketpair/test.ml +++ b/testsuite/tests/lib-unix/win-socketpair/test.ml @@ -1,18 +1,19 @@ (* TEST - -* libwin32unix - script = "sh ${test_source_directory}/has-afunix.sh" -** hassysthreads - include systhreads -*** script -**** bytecode -output = "${test_build_directory}/program-output" -stdout = "${output}" -**** native -output = "${test_build_directory}/program-output" -stdout = "${output}" - - *) + script = "sh ${test_source_directory}/has-afunix.sh"; + libwin32unix; + include systhreads; + hassysthreads; + script; + { + output = "${test_build_directory}/program-output"; + stdout = "${output}"; + bytecode; + }{ + output = "${test_build_directory}/program-output"; + stdout = "${output}"; + native; + } +*) let peer id fd = let msg = Bytes.of_string (Printf.sprintf "%d" id) in diff --git a/testsuite/tests/lib-unix/win-stat/test.ml b/testsuite/tests/lib-unix/win-stat/test.ml index 982cf5c48c..a4722e2342 100644 --- a/testsuite/tests/lib-unix/win-stat/test.ml +++ b/testsuite/tests/lib-unix/win-stat/test.ml @@ -1,9 +1,12 @@ (* TEST -modules = "fakeclock.c" -* libwin32unix -include unix -** bytecode -** native + modules = "fakeclock.c"; + include unix; + libwin32unix; + { + bytecode; + }{ + native; + } *) external set_fake_clock : int64 -> unit = "set_fake_clock" diff --git a/testsuite/tests/lib-unix/win-symlink/parallel_symlink.ml b/testsuite/tests/lib-unix/win-symlink/parallel_symlink.ml index d27e7db02d..3d36ad1935 100644 --- a/testsuite/tests/lib-unix/win-symlink/parallel_symlink.ml +++ b/testsuite/tests/lib-unix/win-symlink/parallel_symlink.ml @@ -1,9 +1,12 @@ (* TEST -* libwin32unix -include unix -** has_symlink -*** bytecode -*** native + include unix; + libwin32unix; + has_symlink; + { + bytecode; + }{ + native; + } *) let create_symlink barrier src dst () = diff --git a/testsuite/tests/lib-unix/win-symlink/test.ml b/testsuite/tests/lib-unix/win-symlink/test.ml index d9b9f29e50..72426a23df 100644 --- a/testsuite/tests/lib-unix/win-symlink/test.ml +++ b/testsuite/tests/lib-unix/win-symlink/test.ml @@ -1,11 +1,12 @@ (* TEST - -* libwin32unix - include unix -** has_symlink -*** bytecode -*** native - + include unix; + libwin32unix; + has_symlink; + { + bytecode; + }{ + native; + } *) let link1 = "link1" diff --git a/testsuite/tests/link-test/empty.ml b/testsuite/tests/link-test/empty.ml index d38300bb8d..5065877bd1 100644 --- a/testsuite/tests/link-test/empty.ml +++ b/testsuite/tests/link-test/empty.ml @@ -1,29 +1,31 @@ (* TEST - -* setup-ocamlc.byte-build-env -** ocamlc.byte -module = "empty.ml" -*** ocamlc.byte -module = "" -flags = "-a" -all_modules = "" -program = "empty.cma" -**** ocamlc.byte -flags = "" -program = "${test_build_directory}/empty.byte" -all_modules = "empty.cma empty.cmo" -***** check-ocamlc.byte-output -* setup-ocamlopt.byte-build-env -** ocamlopt.byte -module = "empty.ml" -*** ocamlopt.byte -module = "" -flags = "-a" -all_modules = "" -program = "empty.cmxa" -**** ocamlopt.byte -flags = "" -program = "${test_build_directory}/empty.native" -all_modules = "empty.cmxa empty.cmx" -***** check-ocamlopt.byte-output + { + setup-ocamlc.byte-build-env; + module = "empty.ml"; + ocamlc.byte; + module = ""; + flags = "-a"; + all_modules = ""; + program = "empty.cma"; + ocamlc.byte; + flags = ""; + program = "${test_build_directory}/empty.byte"; + all_modules = "empty.cma empty.cmo"; + ocamlc.byte; + check-ocamlc.byte-output; + }{ + setup-ocamlopt.byte-build-env; + module = "empty.ml"; + ocamlopt.byte; + module = ""; + flags = "-a"; + all_modules = ""; + program = "empty.cmxa"; + ocamlopt.byte; + flags = ""; + program = "${test_build_directory}/empty.native"; + all_modules = "empty.cmxa empty.cmx"; + ocamlopt.byte; + check-ocamlopt.byte-output; + } *) diff --git a/testsuite/tests/link-test/test.ml b/testsuite/tests/link-test/test.ml index 7b618baa44..a28970ea73 100644 --- a/testsuite/tests/link-test/test.ml +++ b/testsuite/tests/link-test/test.ml @@ -1,84 +1,82 @@ (* TEST - -modules = "aliases.ml external_for_pack.ml external.ml submodule.ml test.ml \ - use_in_pack.ml" - -* setup-ocamlc.byte-build-env -program = "${test_build_directory}/test.byte" -** ocamlc.byte -module = "submodule.ml" -flags = "-no-alias-deps" -*** ocamlc.byte -module = "aliases.ml" -**** ocamlc.byte -module = "external.mli" -***** ocamlc.byte -module = "external.ml" -****** ocamlc.byte -module = "external_for_pack.mli" -******* ocamlc.byte -module = "external_for_pack.ml" -******** ocamlc.byte -module = "test.ml" -********* ocamlc.byte -module = "" -flags = "-a -no-alias-deps" -all_modules = "submodule.cmo aliases.cmo external.cmo external_for_pack.cmo" -program = "mylib.cma" -********** ocamlc.byte -flags = "-no-alias-deps -for-pack P" -module = "use_in_pack.ml" -*********** ocamlc.byte -module = "" -program = "p.cmo" -flags = "-no-alias-deps -pack" -all_modules = "use_in_pack.cmo" -************ ocamlc.byte -program = "${test_build_directory}/test.byte" -all_modules = "mylib.cma p.cmo test.cmo" -flags= "-no-alias-deps" -************* check-ocamlc.byte-output -************** run -*************** check-program-output - -* setup-ocamlopt.byte-build-env -program = "${test_build_directory}/test.opt" -** ocamlopt.byte -module = "submodule.ml" -flags = "-no-alias-deps" -*** ocamlopt.byte -module = "aliases.ml" -**** ocamlopt.byte -module = "external.mli" -***** ocamlopt.byte -module = "external.ml" -****** ocamlopt.byte -module = "external_for_pack.mli" -******* ocamlopt.byte -module = "external_for_pack.ml" -******** ocamlopt.byte -module = "test.ml" -********* ocamlopt.byte -module = "" -flags = "-no-alias-deps -a" -all_modules = "submodule.cmx aliases.cmx external.cmx external_for_pack.cmx" -program = "mylib.cmxa" -********** ocamlopt.byte -flags = "-no-alias-deps -for-pack P" -module = "use_in_pack.ml" -*********** ocamlopt.byte -module = "" -program = "p.cmx" -flags = "-no-alias-deps -pack" -all_modules = "use_in_pack.cmx" -************ ocamlopt.byte -program = "${test_build_directory}/test.opt" -all_modules = "mylib.cmxa p.cmx test.cmx" -flags = "-no-alias-deps" -************* check-ocamlopt.byte-output -************** run -*************** check-program-output - + modules = "aliases.ml external_for_pack.ml external.ml submodule.ml test.ml use_in_pack.ml"; + { + program = "${test_build_directory}/test.byte"; + setup-ocamlc.byte-build-env; + module = "submodule.ml"; + flags = "-no-alias-deps"; + ocamlc.byte; + module = "aliases.ml"; + ocamlc.byte; + module = "external.mli"; + ocamlc.byte; + module = "external.ml"; + ocamlc.byte; + module = "external_for_pack.mli"; + ocamlc.byte; + module = "external_for_pack.ml"; + ocamlc.byte; + module = "test.ml"; + ocamlc.byte; + module = ""; + flags = "-a -no-alias-deps"; + all_modules = "submodule.cmo aliases.cmo external.cmo external_for_pack.cmo"; + program = "mylib.cma"; + ocamlc.byte; + flags = "-no-alias-deps -for-pack P"; + module = "use_in_pack.ml"; + ocamlc.byte; + module = ""; + program = "p.cmo"; + flags = "-no-alias-deps -pack"; + all_modules = "use_in_pack.cmo"; + ocamlc.byte; + program = "${test_build_directory}/test.byte"; + all_modules = "mylib.cma p.cmo test.cmo"; + flags = "-no-alias-deps"; + ocamlc.byte; + check-ocamlc.byte-output; + run; + check-program-output; + }{ + program = "${test_build_directory}/test.opt"; + setup-ocamlopt.byte-build-env; + module = "submodule.ml"; + flags = "-no-alias-deps"; + ocamlopt.byte; + module = "aliases.ml"; + ocamlopt.byte; + module = "external.mli"; + ocamlopt.byte; + module = "external.ml"; + ocamlopt.byte; + module = "external_for_pack.mli"; + ocamlopt.byte; + module = "external_for_pack.ml"; + ocamlopt.byte; + module = "test.ml"; + ocamlopt.byte; + module = ""; + flags = "-no-alias-deps -a"; + all_modules = "submodule.cmx aliases.cmx external.cmx external_for_pack.cmx"; + program = "mylib.cmxa"; + ocamlopt.byte; + flags = "-no-alias-deps -for-pack P"; + module = "use_in_pack.ml"; + ocamlopt.byte; + module = ""; + program = "p.cmx"; + flags = "-no-alias-deps -pack"; + all_modules = "use_in_pack.cmx"; + ocamlopt.byte; + program = "${test_build_directory}/test.opt"; + all_modules = "mylib.cmxa p.cmx test.cmx"; + flags = "-no-alias-deps"; + ocamlopt.byte; + check-ocamlopt.byte-output; + run; + check-program-output; + } *) include Aliases.Submodule.M diff --git a/testsuite/tests/load_path/test.ml b/testsuite/tests/load_path/test.ml index 20a1800c12..aba49ca378 100644 --- a/testsuite/tests/load_path/test.ml +++ b/testsuite/tests/load_path/test.ml @@ -1,9 +1,7 @@ (* TEST - -subdirectories = "test" - -* setup-ocaml-build-env -** ocaml -test_file = "test/driver.ml" -ocaml_script_as_argument = "true" + subdirectories = "test"; + setup-ocaml-build-env; + test_file = "test/driver.ml"; + ocaml_script_as_argument = "true"; + ocaml; *) diff --git a/testsuite/tests/local-functions/non_local.ml b/testsuite/tests/local-functions/non_local.ml index 684cb0c5f0..6b32f05e34 100644 --- a/testsuite/tests/local-functions/non_local.ml +++ b/testsuite/tests/local-functions/non_local.ml @@ -1,4 +1,4 @@ -(* TEST *) +(* TEST_BELOW*) (* Basic case: local optimisation works *) let local_direct x = @@ -20,3 +20,6 @@ let local_inner_scope x = let local_in_function x = let[@local] f y = x + y in List.map (fun x -> f (succ x)) [0] + +(* TEST +*) diff --git a/testsuite/tests/local-functions/tupled.ml b/testsuite/tests/local-functions/tupled.ml index aef5aacb27..fb1d9caa3c 100644 --- a/testsuite/tests/local-functions/tupled.ml +++ b/testsuite/tests/local-functions/tupled.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) (* PR#8705 *) let () = diff --git a/testsuite/tests/local-functions/tupled2.ml b/testsuite/tests/local-functions/tupled2.ml index e1564980d6..fa2eebe8c5 100644 --- a/testsuite/tests/local-functions/tupled2.ml +++ b/testsuite/tests/local-functions/tupled2.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) (* PR#8705 *) diff --git a/testsuite/tests/locale/test.ml b/testsuite/tests/locale/test.ml index dbd4f449d3..6798138688 100644 --- a/testsuite/tests/locale/test.ml +++ b/testsuite/tests/locale/test.ml @@ -1,5 +1,5 @@ (* TEST -modules = "stubs.c" + modules = "stubs.c"; *) external setlocale : string -> unit = "ml_setlocale" diff --git a/testsuite/tests/manual-intf-c/prog.ml b/testsuite/tests/manual-intf-c/prog.ml index 9a9e6845ca..260291c962 100644 --- a/testsuite/tests/manual-intf-c/prog.ml +++ b/testsuite/tests/manual-intf-c/prog.ml @@ -1,15 +1,16 @@ (* TEST -(* Tests from manual, section intf-c *) -(* - This test is currently skipped because there is no proper way to - figure out whether Curses is available or not. If it becomes possible - to figure that out, it would be nice to be able to check that the test - compiles. Executing seems lessrelevant. -*) -* skip -reason = "curses can not be properly detected at the moment" + (* + This test is currently skipped because there is no proper way to + figure out whether Curses is available or not. If it becomes possible + to figure that out, it would be nice to be able to check that the test + compiles. Executing seems lessrelevant. + *) + reason = "curses can not be properly detected at the moment"; + skip; *) +(* Tests from manual, section intf-c *) + (* File prog.ml -- main program using curses *) open Curses;; let main_window = initscr () in diff --git a/testsuite/tests/match-exception-warnings/exhaustiveness_warnings.ml b/testsuite/tests/match-exception-warnings/exhaustiveness_warnings.ml index f062524cdb..63cd731b72 100644 --- a/testsuite/tests/match-exception-warnings/exhaustiveness_warnings.ml +++ b/testsuite/tests/match-exception-warnings/exhaustiveness_warnings.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (** Test exhaustiveness. diff --git a/testsuite/tests/match-exception-warnings/no_mixing_under_guard.ml b/testsuite/tests/match-exception-warnings/no_mixing_under_guard.ml index 225d53054d..ee0c9b4950 100644 --- a/testsuite/tests/match-exception-warnings/no_mixing_under_guard.ml +++ b/testsuite/tests/match-exception-warnings/no_mixing_under_guard.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) exception Exit diff --git a/testsuite/tests/match-exception-warnings/no_value_clauses.ml b/testsuite/tests/match-exception-warnings/no_value_clauses.ml index 77996e5bd4..8ce6ac3781 100644 --- a/testsuite/tests/match-exception-warnings/no_value_clauses.ml +++ b/testsuite/tests/match-exception-warnings/no_value_clauses.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) let test f = diff --git a/testsuite/tests/match-exception-warnings/placement.ml b/testsuite/tests/match-exception-warnings/placement.ml index c93247e357..ca7113cbc1 100644 --- a/testsuite/tests/match-exception-warnings/placement.ml +++ b/testsuite/tests/match-exception-warnings/placement.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (*****************************************************) diff --git a/testsuite/tests/match-exception-warnings/pr7083.ml b/testsuite/tests/match-exception-warnings/pr7083.ml index cf8ddd642d..cdf7f2af41 100644 --- a/testsuite/tests/match-exception-warnings/pr7083.ml +++ b/testsuite/tests/match-exception-warnings/pr7083.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) let f x = diff --git a/testsuite/tests/match-exception-warnings/reachability.ml b/testsuite/tests/match-exception-warnings/reachability.ml index 7c56ca2f05..9549c50eaa 100644 --- a/testsuite/tests/match-exception-warnings/reachability.ml +++ b/testsuite/tests/match-exception-warnings/reachability.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) let f x = diff --git a/testsuite/tests/match-exception/allocation.ml b/testsuite/tests/match-exception/allocation.ml index a99dc83e95..d7acd758d2 100644 --- a/testsuite/tests/match-exception/allocation.ml +++ b/testsuite/tests/match-exception/allocation.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) (** Test that matching multiple values doesn't allocate a block. *) diff --git a/testsuite/tests/match-exception/exception_propagation.ml b/testsuite/tests/match-exception/exception_propagation.ml index 759ec386c9..57275f6180 100644 --- a/testsuite/tests/match-exception/exception_propagation.ml +++ b/testsuite/tests/match-exception/exception_propagation.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) (** Test that match allows exceptions to propagate. diff --git a/testsuite/tests/match-exception/identifier_sharing.ml b/testsuite/tests/match-exception/identifier_sharing.ml index e0bb3890ee..9df7c5e0ed 100644 --- a/testsuite/tests/match-exception/identifier_sharing.ml +++ b/testsuite/tests/match-exception/identifier_sharing.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) exception String of string diff --git a/testsuite/tests/match-exception/match_failure.ml b/testsuite/tests/match-exception/match_failure.ml index a6c3d8122e..60e26f6b9d 100644 --- a/testsuite/tests/match-exception/match_failure.ml +++ b/testsuite/tests/match-exception/match_failure.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) (** Test that value match failure in a match block raises Match_failure. diff --git a/testsuite/tests/match-exception/nested_handlers.ml b/testsuite/tests/match-exception/nested_handlers.ml index 6f019d4b4b..c23fb983ca 100644 --- a/testsuite/tests/match-exception/nested_handlers.ml +++ b/testsuite/tests/match-exception/nested_handlers.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) (* Test that multiple handlers coexist happily. diff --git a/testsuite/tests/match-exception/raise_from_success_continuation.ml b/testsuite/tests/match-exception/raise_from_success_continuation.ml index 69a82371cd..af71feb9fa 100644 --- a/testsuite/tests/match-exception/raise_from_success_continuation.ml +++ b/testsuite/tests/match-exception/raise_from_success_continuation.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) (** Test raising exceptions from a value-matching branch. diff --git a/testsuite/tests/match-exception/streams.ml b/testsuite/tests/match-exception/streams.ml index b438227124..a9a4c9e81a 100644 --- a/testsuite/tests/match-exception/streams.ml +++ b/testsuite/tests/match-exception/streams.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) (** Test the stream example . diff --git a/testsuite/tests/match-exception/tail_calls.ml b/testsuite/tests/match-exception/tail_calls.ml index ae72fc9317..cdad8d927d 100644 --- a/testsuite/tests/match-exception/tail_calls.ml +++ b/testsuite/tests/match-exception/tail_calls.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) (** The success continuation expression is in tail position. diff --git a/testsuite/tests/memory-model/forbidden.ml b/testsuite/tests/memory-model/forbidden.ml index 5504d94f04..dac3be076f 100644 --- a/testsuite/tests/memory-model/forbidden.ml +++ b/testsuite/tests/memory-model/forbidden.ml @@ -1,8 +1,11 @@ (* TEST - modules="opt.ml barrier.ml hist.ml shared.ml run.ml outcome.ml" - * not-bsd - ** bytecode - ** native + modules = "opt.ml barrier.ml hist.ml shared.ml run.ml outcome.ml"; + not-bsd; + { + bytecode; + }{ + native; + } *) (* Memory model test: diff --git a/testsuite/tests/memory-model/publish.ml b/testsuite/tests/memory-model/publish.ml index 7f778307a1..e5750d3636 100644 --- a/testsuite/tests/memory-model/publish.ml +++ b/testsuite/tests/memory-model/publish.ml @@ -1,9 +1,12 @@ (* TEST - modules="opt.ml barrier.ml hist.ml shared.ml run.ml outcome.ml" - * not-bsd - ** not-windows - *** bytecode - ** native + modules = "opt.ml barrier.ml hist.ml shared.ml run.ml outcome.ml"; + not-bsd; + { + not-windows; + bytecode; + }{ + native; + } *) (* Memory model: test the _publish idiom *) diff --git a/testsuite/tests/messages/highlight_tabs.ml b/testsuite/tests/messages/highlight_tabs.ml index 9a065a45c3..6570cac440 100644 --- a/testsuite/tests/messages/highlight_tabs.ml +++ b/testsuite/tests/messages/highlight_tabs.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) let x = abc diff --git a/testsuite/tests/messages/precise_locations.ml b/testsuite/tests/messages/precise_locations.ml index aecd8a5ab3..f748b43b76 100644 --- a/testsuite/tests/messages/precise_locations.ml +++ b/testsuite/tests/messages/precise_locations.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type t = (unit, unit, unit, unit) bar diff --git a/testsuite/tests/messages/spellcheck.ml b/testsuite/tests/messages/spellcheck.ml index 9c852668de..1752431275 100644 --- a/testsuite/tests/messages/spellcheck.ml +++ b/testsuite/tests/messages/spellcheck.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* The goal of this test is exhaustively cover all spellcheck-style diff --git a/testsuite/tests/misc-kb/kbmain.ml b/testsuite/tests/misc-kb/kbmain.ml index 6e94ecd0a7..d39d709bdb 100644 --- a/testsuite/tests/misc-kb/kbmain.ml +++ b/testsuite/tests/misc-kb/kbmain.ml @@ -1,5 +1,5 @@ (* TEST - modules = "terms.ml equations.ml orderings.ml kb.ml" + modules = "terms.ml equations.ml orderings.ml kb.ml"; *) open Terms diff --git a/testsuite/tests/misc-unsafe/almabench.ml b/testsuite/tests/misc-unsafe/almabench.ml index 253db390e2..90620511d2 100644 --- a/testsuite/tests/misc-unsafe/almabench.ml +++ b/testsuite/tests/misc-unsafe/almabench.ml @@ -1,5 +1,5 @@ (* TEST - flags += " -unsafe " + flags += " -unsafe "; *) (* diff --git a/testsuite/tests/misc-unsafe/fft.ml b/testsuite/tests/misc-unsafe/fft.ml index 463e5c9dd2..381937383c 100644 --- a/testsuite/tests/misc-unsafe/fft.ml +++ b/testsuite/tests/misc-unsafe/fft.ml @@ -1,5 +1,5 @@ (* TEST - flags += " -unsafe " + flags += " -unsafe "; *) let pi = 3.14159265358979323846 diff --git a/testsuite/tests/misc-unsafe/quicksort.ml b/testsuite/tests/misc-unsafe/quicksort.ml index 208e2052fb..6f98983658 100644 --- a/testsuite/tests/misc-unsafe/quicksort.ml +++ b/testsuite/tests/misc-unsafe/quicksort.ml @@ -1,5 +1,5 @@ (* TEST - flags += " -unsafe " + flags += " -unsafe "; *) (* Good test for loops. Best compiled with -unsafe. *) diff --git a/testsuite/tests/misc-unsafe/soli.ml b/testsuite/tests/misc-unsafe/soli.ml index 127cd69923..92a4e52b87 100644 --- a/testsuite/tests/misc-unsafe/soli.ml +++ b/testsuite/tests/misc-unsafe/soli.ml @@ -1,5 +1,5 @@ (* TEST - flags += " -unsafe " + flags += " -unsafe "; *) type peg = Out | Empty | Peg diff --git a/testsuite/tests/misc/bdd.ml b/testsuite/tests/misc/bdd.ml index 30de85e016..f471ab9f0c 100644 --- a/testsuite/tests/misc/bdd.ml +++ b/testsuite/tests/misc/bdd.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) (* Translated to OCaml by Xavier Leroy *) (* Original code written in SML by ... *) diff --git a/testsuite/tests/misc/boyer.ml b/testsuite/tests/misc/boyer.ml index 53e18813a2..736b3524c8 100644 --- a/testsuite/tests/misc/boyer.ml +++ b/testsuite/tests/misc/boyer.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) (* Manipulations over terms *) diff --git a/testsuite/tests/misc/exotic.ml b/testsuite/tests/misc/exotic.ml index c8a40a6f4c..dae81075f7 100644 --- a/testsuite/tests/misc/exotic.ml +++ b/testsuite/tests/misc/exotic.ml @@ -1,6 +1,6 @@ (* TEST - flags = "-I ${ocamlsrcdir}/utils" - * expect + flags = "-I ${ocamlsrcdir}/utils"; + expect; *) (* Strict-sequence can change the behavior of programs *) diff --git a/testsuite/tests/misc/fib.ml b/testsuite/tests/misc/fib.ml index 46c34193d7..f46e4211a5 100644 --- a/testsuite/tests/misc/fib.ml +++ b/testsuite/tests/misc/fib.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) let rec fib n = if n < 2 then 1 else fib(n-1) + fib(n-2) diff --git a/testsuite/tests/misc/gc_mark_stack_overflow.ml b/testsuite/tests/misc/gc_mark_stack_overflow.ml index 55dd14a7bd..81b7dd8f1e 100644 --- a/testsuite/tests/misc/gc_mark_stack_overflow.ml +++ b/testsuite/tests/misc/gc_mark_stack_overflow.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) let clear_elements a m = for i = 1 to m do diff --git a/testsuite/tests/misc/gcwords.ml b/testsuite/tests/misc/gcwords.ml index 45125adc6c..877d50cf8f 100644 --- a/testsuite/tests/misc/gcwords.ml +++ b/testsuite/tests/misc/gcwords.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) type t = Leaf of int | Branch of t * t diff --git a/testsuite/tests/misc/gpr1370.ml b/testsuite/tests/misc/gpr1370.ml index 9cd0fedfa5..3f76d7f771 100644 --- a/testsuite/tests/misc/gpr1370.ml +++ b/testsuite/tests/misc/gpr1370.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) type t = A|B|C|D type s = diff --git a/testsuite/tests/misc/hamming.ml b/testsuite/tests/misc/hamming.ml index f4010ac47a..8112a10142 100644 --- a/testsuite/tests/misc/hamming.ml +++ b/testsuite/tests/misc/hamming.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) (* We cannot use bignums because we don't do custom runtimes, but int64 is a bit short, so we roll our own 37-digit numbers... diff --git a/testsuite/tests/misc/nucleic.ml b/testsuite/tests/misc/nucleic.ml index f83bc0467e..112765bbbd 100644 --- a/testsuite/tests/misc/nucleic.ml +++ b/testsuite/tests/misc/nucleic.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) (* Use floating-point arithmetic *) diff --git a/testsuite/tests/misc/pr7168.ml b/testsuite/tests/misc/pr7168.ml index dcd56eed13..03b1b6e4a3 100644 --- a/testsuite/tests/misc/pr7168.ml +++ b/testsuite/tests/misc/pr7168.ml @@ -1,6 +1,5 @@ (* TEST - -ocamlrunparam += "l=100000" + ocamlrunparam += "l=100000"; *) let rec f x = diff --git a/testsuite/tests/misc/sieve.ml b/testsuite/tests/misc/sieve.ml index 1dd83a0ec9..7a6325d0fc 100644 --- a/testsuite/tests/misc/sieve.ml +++ b/testsuite/tests/misc/sieve.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) (* Eratosthene's sieve *) diff --git a/testsuite/tests/misc/sorts.ml b/testsuite/tests/misc/sorts.ml index 445c48419f..3e7214f6bf 100644 --- a/testsuite/tests/misc/sorts.ml +++ b/testsuite/tests/misc/sorts.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) (* Test bench for sorting algorithms. *) diff --git a/testsuite/tests/misc/takc.ml b/testsuite/tests/misc/takc.ml index bfdf11c45c..5b1632af77 100644 --- a/testsuite/tests/misc/takc.ml +++ b/testsuite/tests/misc/takc.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) let rec tak x y z = if x > y then tak (tak (x-1) y z) (tak (y-1) z x) (tak (z-1) x y) diff --git a/testsuite/tests/misc/taku.ml b/testsuite/tests/misc/taku.ml index dac1a3f61e..b73001c216 100644 --- a/testsuite/tests/misc/taku.ml +++ b/testsuite/tests/misc/taku.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) let rec tak (x, y, z) = if x > y then tak(tak (x-1, y, z), tak (y-1, z, x), tak (z-1, x, y)) diff --git a/testsuite/tests/no-alias-deps/aliases.ml b/testsuite/tests/no-alias-deps/aliases.ml index 6da3f709d5..41277205ef 100644 --- a/testsuite/tests/no-alias-deps/aliases.ml +++ b/testsuite/tests/no-alias-deps/aliases.ml @@ -1,17 +1,17 @@ -(* TEST -flags = "-no-alias-deps" -compile_only = "true" -readonly_files = "b.cmi.in c.mli d.mli" -* setup-ocamlc.byte-build-env -** copy -src = "b.cmi.in" -dst = "b.cmi" -*** ocamlc.byte -all_modules = "c.mli d.mli aliases.ml" -**** check-ocamlc.byte-output -***** ocamlobjinfo -program = "aliases.cmo" -****** check-program-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + + + + + + + + + *) module A' = A (* missing a.cmi *) @@ -19,3 +19,19 @@ module B' = B (* broken b.cmi *) module C' = C (* valid c.cmi *) module D' = D (* valid d.cmi *) let () = print_int D'.something + +(* TEST + flags = "-no-alias-deps"; + compile_only = "true"; + readonly_files = "b.cmi.in c.mli d.mli"; + setup-ocamlc.byte-build-env; + src = "b.cmi.in"; + dst = "b.cmi"; + copy; + all_modules = "c.mli d.mli aliases.ml"; + ocamlc.byte; + check-ocamlc.byte-output; + program = "aliases.cmo"; + ocamlobjinfo; + check-program-output; +*) diff --git a/testsuite/tests/no-alias-deps/gpr2235.ml b/testsuite/tests/no-alias-deps/gpr2235.ml index 96472f3ade..aa038b5da8 100644 --- a/testsuite/tests/no-alias-deps/gpr2235.ml +++ b/testsuite/tests/no-alias-deps/gpr2235.ml @@ -1,21 +1,21 @@ (* TEST -flags = "-no-alias-deps -w -49" -compile_only = "true" -readonly_files = "a2235.ml lib__2235.ml lib2235.ml user_of_lib2235.ml" -* setup-ocamlc.byte-build-env -** ocamlc.byte -module = "lib__2235.ml" -*** check-ocamlc.byte-output -**** ocamlc.byte -flags = "-no-alias-deps -w -49 -open Lib__2235 -o lib__A2235.cmo" -module = "a2235.ml" -***** check-ocamlc.byte-output -****** ocamlc.byte -flags = "-no-alias-deps -w -49 -open Lib__2235" -module = "lib2235.ml" -******* check-ocamlc.byte-output -******** ocamlc.byte -flags = "-no-alias-deps -w -49" -module = "user_of_lib2235.ml" -********* check-ocamlc.byte-output + flags = "-no-alias-deps -w -49"; + compile_only = "true"; + readonly_files = "a2235.ml lib__2235.ml lib2235.ml user_of_lib2235.ml"; + setup-ocamlc.byte-build-env; + module = "lib__2235.ml"; + ocamlc.byte; + check-ocamlc.byte-output; + flags = "-no-alias-deps -w -49 -open Lib__2235 -o lib__A2235.cmo"; + module = "a2235.ml"; + ocamlc.byte; + check-ocamlc.byte-output; + flags = "-no-alias-deps -w -49 -open Lib__2235"; + module = "lib2235.ml"; + ocamlc.byte; + check-ocamlc.byte-output; + flags = "-no-alias-deps -w -49"; + module = "user_of_lib2235.ml"; + ocamlc.byte; + check-ocamlc.byte-output; *) diff --git a/testsuite/tests/opaque/test.ml b/testsuite/tests/opaque/test.ml index 4af63ede52..c7bf838c1a 100644 --- a/testsuite/tests/opaque/test.ml +++ b/testsuite/tests/opaque/test.ml @@ -1,65 +1,56 @@ (* TEST - -subdirectories = "fst intf snd" - -compile_only = "true" - -* setup-ocamlopt.byte-build-env -** ocamlopt.byte -flags = "-I intf -opaque" -all_modules = "intf/opaque_intf.mli" -*** ocamlopt.byte -flags = "-I intf" -all_modules = "intf/opaque_impl.mli intf/regular.mli" -**** copy -src = "intf/opaque_intf.cmi intf/opaque_impl.cmi intf/regular.cmi \ - intf/opaque_intf.mli intf/opaque_impl.mli intf/regular.mli" -dst = "fst/" -***** copy -src = "intf/opaque_intf.cmi intf/opaque_impl.cmi intf/regular.cmi \ - intf/opaque_intf.mli intf/opaque_impl.mli intf/regular.mli" -dst = "snd/" -****** ocamlopt.byte -flags = "-I fst -opaque" -all_modules = "fst/opaque_impl.ml" -******* ocamlopt.byte -flags = "-I snd -opaque" -all_modules = "snd/opaque_impl.ml" -******** ocamlopt.byte -flags = "-I fst" -all_modules = "fst/opaque_intf.ml fst/regular.ml" -********* ocamlopt.byte -flags = "-I snd" -all_modules = "snd/opaque_intf.ml snd/regular.ml" -********** ocamlopt.byte -flags = "-I fst" -all_modules = "test.ml" - -(* ordinary compilation *) -*********** ocamlopt.byte -compile_only = "false" -all_modules = "fst/opaque_intf.cmx fst/opaque_impl.cmx fst/regular.cmx test.cmx" -program = "${test_build_directory}/p1.exe" - -(* change to opaque interface *) -*********** ocamlopt.byte -compile_only = "false" -all_modules = "snd/opaque_intf.cmx fst/opaque_impl.cmx fst/regular.cmx test.cmx" -program = "${test_build_directory}/p2.exe" - -(* change to opaque implementation *) -*********** ocamlopt.byte -compile_only = "false" -all_modules = "fst/opaque_intf.cmx snd/opaque_impl.cmx fst/regular.cmx test.cmx" -program = "${test_build_directory}/p3.exe" - -(* change to non-opaque implementation *) -*********** ocamlopt.byte -compile_only = "false" -all_modules = "fst/opaque_intf.cmx fst/opaque_impl.cmx snd/regular.cmx test.cmx" -program = "${test_build_directory}/p4.exe" -ocamlopt_byte_exit_status = "2" - + subdirectories = "fst intf snd"; + compile_only = "true"; + setup-ocamlopt.byte-build-env; + flags = "-I intf -opaque"; + all_modules = "intf/opaque_intf.mli"; + ocamlopt.byte; + flags = "-I intf"; + all_modules = "intf/opaque_impl.mli intf/regular.mli"; + ocamlopt.byte; + src = "intf/opaque_intf.cmi intf/opaque_impl.cmi intf/regular.cmi intf/opaque_intf.mli intf/opaque_impl.mli intf/regular.mli"; + dst = "fst/"; + copy; + src = "intf/opaque_intf.cmi intf/opaque_impl.cmi intf/regular.cmi intf/opaque_intf.mli intf/opaque_impl.mli intf/regular.mli"; + dst = "snd/"; + copy; + flags = "-I fst -opaque"; + all_modules = "fst/opaque_impl.ml"; + ocamlopt.byte; + flags = "-I snd -opaque"; + all_modules = "snd/opaque_impl.ml"; + ocamlopt.byte; + flags = "-I fst"; + all_modules = "fst/opaque_intf.ml fst/regular.ml"; + ocamlopt.byte; + flags = "-I snd"; + all_modules = "snd/opaque_intf.ml snd/regular.ml"; + ocamlopt.byte; + flags = "-I fst"; + all_modules = "test.ml"; + ocamlopt.byte; + { (* ordinary compilation *) + compile_only = "false"; + all_modules = "fst/opaque_intf.cmx fst/opaque_impl.cmx fst/regular.cmx test.cmx"; + program = "${test_build_directory}/p1.exe"; + ocamlopt.byte; + }{ (* change to opaque interface *) + compile_only = "false"; + all_modules = "snd/opaque_intf.cmx fst/opaque_impl.cmx fst/regular.cmx test.cmx"; + program = "${test_build_directory}/p2.exe"; + ocamlopt.byte; + }{ (* change to opaque implementation *) + compile_only = "false"; + all_modules = "fst/opaque_intf.cmx snd/opaque_impl.cmx fst/regular.cmx test.cmx"; + program = "${test_build_directory}/p3.exe"; + ocamlopt.byte; + }{ (* change to non-opaque implementation *) + compile_only = "false"; + all_modules = "fst/opaque_intf.cmx fst/opaque_impl.cmx snd/regular.cmx test.cmx"; + program = "${test_build_directory}/p4.exe"; + ocamlopt_byte_exit_status = "2"; + ocamlopt.byte; + } *) let () = diff --git a/testsuite/tests/output-complete-obj/github9344.ml b/testsuite/tests/output-complete-obj/github9344.ml index b7ea5c5ec6..cef13069b5 100644 --- a/testsuite/tests/output-complete-obj/github9344.ml +++ b/testsuite/tests/output-complete-obj/github9344.ml @@ -1,14 +1,12 @@ (* TEST - -use_runtime = "false" - -* setup-ocamlc.byte-build-env -** ocamlc.byte -flags = "-w -a -output-complete-exe -ccopt -I${ocamlsrcdir}/runtime" -program = "github9344" -*** run -program = "sh ${test_source_directory}/github9344.sh" -**** check-program-output + use_runtime = "false"; + setup-ocamlc.byte-build-env; + flags = "-w -a -output-complete-exe -ccopt -I${ocamlsrcdir}/runtime"; + program = "github9344"; + ocamlc.byte; + program = "sh ${test_source_directory}/github9344.sh"; + run; + check-program-output; *) raise Not_found diff --git a/testsuite/tests/output-complete-obj/test.ml b/testsuite/tests/output-complete-obj/test.ml index 1b655a6d46..bcdb3965f2 100644 --- a/testsuite/tests/output-complete-obj/test.ml +++ b/testsuite/tests/output-complete-obj/test.ml @@ -1,32 +1,30 @@ (* TEST - -readonly_files = "test.ml_stub.c" - -* setup-ocamlc.byte-build-env -** ocamlc.byte -flags = "-w -a -output-complete-obj" -program = "test.ml.bc.${objext}" -*** script -script = "${mkexe} -I${ocamlsrcdir}/runtime -o test.ml_bc_stub.exe \ - test.ml.bc.${objext} ${nativecc_libs} test.ml_stub.c" -output = "${compiler_output}" -**** run -program = "./test.ml_bc_stub.exe" -stdout = "program-output" -stderr = "program-output" -* setup-ocamlopt.byte-build-env -** ocamlopt.byte -flags = "-w -a -output-complete-obj" -program = "test.ml.exe.${objext}" -*** script -script = "${mkexe} -I${ocamlsrcdir}/runtime -o test.ml_stub.exe \ - test.ml.exe.${objext} ${bytecc_libs} test.ml_stub.c" -output = "${compiler_output}" -**** run -program = "./test.ml_stub.exe" -stdout = "program-output" -stderr = "program-output" - + readonly_files = "test.ml_stub.c"; + { + setup-ocamlc.byte-build-env; + flags = "-w -a -output-complete-obj"; + program = "test.ml.bc.${objext}"; + ocamlc.byte; + script = "${mkexe} -I${ocamlsrcdir}/runtime -o test.ml_bc_stub.exe test.ml.bc.${objext} ${nativecc_libs} test.ml_stub.c"; + output = "${compiler_output}"; + script; + program = "./test.ml_bc_stub.exe"; + stdout = "program-output"; + stderr = "program-output"; + run; + }{ + setup-ocamlopt.byte-build-env; + flags = "-w -a -output-complete-obj"; + program = "test.ml.exe.${objext}"; + ocamlopt.byte; + script = "${mkexe} -I${ocamlsrcdir}/runtime -o test.ml_stub.exe test.ml.exe.${objext} ${bytecc_libs} test.ml_stub.c"; + output = "${compiler_output}"; + script; + program = "./test.ml_stub.exe"; + stdout = "program-output"; + stderr = "program-output"; + run; + } *) let () = Printf.printf "Test!!\n%!" diff --git a/testsuite/tests/output-complete-obj/test2.ml b/testsuite/tests/output-complete-obj/test2.ml index c201224ce8..a5b7e3f820 100644 --- a/testsuite/tests/output-complete-obj/test2.ml +++ b/testsuite/tests/output-complete-obj/test2.ml @@ -1,18 +1,16 @@ (* TEST - -readonly_files = "puts.c" -use_runtime = "false" -unset FOO - -* hasunix -include unix -** setup-ocamlc.byte-build-env -*** ocamlc.byte -flags = "-w -a -output-complete-exe puts.c -ccopt -I${ocamlsrcdir}/runtime" -program = "test2" -**** run -program = "./test2" -***** check-program-output + readonly_files = "puts.c"; + use_runtime = "false"; + unset FOO; + include unix; + hasunix; + setup-ocamlc.byte-build-env; + flags = "-w -a -output-complete-exe puts.c -ccopt -I${ocamlsrcdir}/runtime"; + program = "test2"; + ocamlc.byte; + program = "./test2"; + run; + check-program-output; *) external puts: string -> unit = "caml_puts" diff --git a/testsuite/tests/parallel/atomics.ml b/testsuite/tests/parallel/atomics.ml index 823fb32dc2..b2c36f6765 100644 --- a/testsuite/tests/parallel/atomics.ml +++ b/testsuite/tests/parallel/atomics.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) type u = U of unit let () = diff --git a/testsuite/tests/parallel/backup_thread.ml b/testsuite/tests/parallel/backup_thread.ml index 05b06cc47c..9804c5b99c 100644 --- a/testsuite/tests/parallel/backup_thread.ml +++ b/testsuite/tests/parallel/backup_thread.ml @@ -1,8 +1,11 @@ (* TEST -* hasunix -include unix -** bytecode -** native + include unix; + hasunix; + { + bytecode; + }{ + native; + } *) diff --git a/testsuite/tests/parallel/backup_thread_pipe.ml b/testsuite/tests/parallel/backup_thread_pipe.ml index 41fd101c1f..471e075eb3 100644 --- a/testsuite/tests/parallel/backup_thread_pipe.ml +++ b/testsuite/tests/parallel/backup_thread_pipe.ml @@ -1,8 +1,11 @@ (* TEST -* hasunix -include unix -** bytecode -** native + include unix; + hasunix; + { + bytecode; + }{ + native; + } *) diff --git a/testsuite/tests/parallel/constpromote.ml b/testsuite/tests/parallel/constpromote.ml index 9bf7ede7a3..2b6bdf075b 100644 --- a/testsuite/tests/parallel/constpromote.ml +++ b/testsuite/tests/parallel/constpromote.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) (* when run with the bytecode debug runtime, this test used to trigger a bug where the constant [13] diff --git a/testsuite/tests/parallel/deadcont.ml b/testsuite/tests/parallel/deadcont.ml index fcdfbec210..5faae5f726 100644 --- a/testsuite/tests/parallel/deadcont.ml +++ b/testsuite/tests/parallel/deadcont.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) (* Test handling of continuations created by a domain that has since terminated. diff --git a/testsuite/tests/parallel/domain_dls.ml b/testsuite/tests/parallel/domain_dls.ml index 72f4ddf0bd..47751aca0e 100644 --- a/testsuite/tests/parallel/domain_dls.ml +++ b/testsuite/tests/parallel/domain_dls.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) let check_dls () = let k1 = Domain.DLS.new_key (fun () -> 10) in diff --git a/testsuite/tests/parallel/domain_dls2.ml b/testsuite/tests/parallel/domain_dls2.ml index ae301bda36..2900ec03a8 100644 --- a/testsuite/tests/parallel/domain_dls2.ml +++ b/testsuite/tests/parallel/domain_dls2.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) let _ = let key_array = diff --git a/testsuite/tests/parallel/domain_id.ml b/testsuite/tests/parallel/domain_id.ml index 540ca905fd..21236277b3 100644 --- a/testsuite/tests/parallel/domain_id.ml +++ b/testsuite/tests/parallel/domain_id.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) open Domain diff --git a/testsuite/tests/parallel/domain_parallel_spawn_burn.ml b/testsuite/tests/parallel/domain_parallel_spawn_burn.ml index ecc9d0b78f..85f09bd98b 100644 --- a/testsuite/tests/parallel/domain_parallel_spawn_burn.ml +++ b/testsuite/tests/parallel/domain_parallel_spawn_burn.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) open Domain diff --git a/testsuite/tests/parallel/domain_parallel_spawn_burn_gc_set.ml b/testsuite/tests/parallel/domain_parallel_spawn_burn_gc_set.ml index 883ab1a5ab..6b8a2c6fa4 100644 --- a/testsuite/tests/parallel/domain_parallel_spawn_burn_gc_set.ml +++ b/testsuite/tests/parallel/domain_parallel_spawn_burn_gc_set.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) open Domain diff --git a/testsuite/tests/parallel/domain_serial_spawn_burn.ml b/testsuite/tests/parallel/domain_serial_spawn_burn.ml index aeac4f71f7..7355b2550a 100644 --- a/testsuite/tests/parallel/domain_serial_spawn_burn.ml +++ b/testsuite/tests/parallel/domain_serial_spawn_burn.ml @@ -1,8 +1,11 @@ (* TEST -* hasunix -include unix -** bytecode -** native + include unix; + hasunix; + { + bytecode; + }{ + native; + } *) open Domain diff --git a/testsuite/tests/parallel/fib_threads.ml b/testsuite/tests/parallel/fib_threads.ml index f6005729b7..c6a28081c4 100644 --- a/testsuite/tests/parallel/fib_threads.ml +++ b/testsuite/tests/parallel/fib_threads.ml @@ -1,8 +1,11 @@ (* TEST -* hassysthreads -include systhreads -** bytecode -** native + include systhreads; + hassysthreads; + { + bytecode; + }{ + native; + } *) diff --git a/testsuite/tests/parallel/join.ml b/testsuite/tests/parallel/join.ml index ee85838527..05cc4ea882 100644 --- a/testsuite/tests/parallel/join.ml +++ b/testsuite/tests/parallel/join.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) let test_size = try int_of_string (Sys.getenv "OCAML_TEST_SIZE") diff --git a/testsuite/tests/parallel/major_gc_wait_backup.ml b/testsuite/tests/parallel/major_gc_wait_backup.ml index e418500774..7c11863047 100644 --- a/testsuite/tests/parallel/major_gc_wait_backup.ml +++ b/testsuite/tests/parallel/major_gc_wait_backup.ml @@ -1,8 +1,11 @@ (* TEST -* hasunix -include unix -** native -** bytecode + include unix; + hasunix; + { + native; + }{ + bytecode; + } *) type 'a tree = Empty | Node of 'a tree * 'a tree diff --git a/testsuite/tests/parallel/mctest.ml b/testsuite/tests/parallel/mctest.ml index c5d82d2dbd..ea339e31ed 100644 --- a/testsuite/tests/parallel/mctest.ml +++ b/testsuite/tests/parallel/mctest.ml @@ -1,8 +1,11 @@ (* TEST -* hasunix -include unix -** bytecode -** native + include unix; + hasunix; + { + bytecode; + }{ + native; + } *) (* diff --git a/testsuite/tests/parallel/multicore_systhreads.ml b/testsuite/tests/parallel/multicore_systhreads.ml index 2f0fcf20b0..a2e1130a7b 100644 --- a/testsuite/tests/parallel/multicore_systhreads.ml +++ b/testsuite/tests/parallel/multicore_systhreads.ml @@ -1,8 +1,11 @@ (* TEST -* hassysthreads -include systhreads -** bytecode -** native + include systhreads; + hassysthreads; + { + bytecode; + }{ + native; + } *) diff --git a/testsuite/tests/parallel/pingpong.ml b/testsuite/tests/parallel/pingpong.ml index 1f29cb6b8b..8f900d6de3 100644 --- a/testsuite/tests/parallel/pingpong.ml +++ b/testsuite/tests/parallel/pingpong.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) let r = ref (Some 0) diff --git a/testsuite/tests/parallel/poll.ml b/testsuite/tests/parallel/poll.ml index 4248ba10cf..e0774ec642 100644 --- a/testsuite/tests/parallel/poll.ml +++ b/testsuite/tests/parallel/poll.ml @@ -1,8 +1,11 @@ (* TEST -* hasunix -include unix -** bytecode -** native + include unix; + hasunix; + { + bytecode; + }{ + native; + } *) let continue = Atomic.make true diff --git a/testsuite/tests/parallel/prodcons_domains.ml b/testsuite/tests/parallel/prodcons_domains.ml index 2e2c09756c..34e5612fda 100644 --- a/testsuite/tests/parallel/prodcons_domains.ml +++ b/testsuite/tests/parallel/prodcons_domains.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) (* Classic producer-consumer *) diff --git a/testsuite/tests/parallel/recommended_domain_count.ml b/testsuite/tests/parallel/recommended_domain_count.ml index 8aedeba202..ec08a2c457 100644 --- a/testsuite/tests/parallel/recommended_domain_count.ml +++ b/testsuite/tests/parallel/recommended_domain_count.ml @@ -1,5 +1,5 @@ (* TEST -modules = "recommended_domain_count_cstubs.c" + modules = "recommended_domain_count_cstubs.c"; *) external get_max_domains : unit -> int = "caml_get_max_domains" diff --git a/testsuite/tests/parallel/recommended_domain_count_unix.ml b/testsuite/tests/parallel/recommended_domain_count_unix.ml index f26038a765..d25d54856a 100644 --- a/testsuite/tests/parallel/recommended_domain_count_unix.ml +++ b/testsuite/tests/parallel/recommended_domain_count_unix.ml @@ -1,8 +1,11 @@ (* TEST -* hasunix -include unix -** bytecode -** native + include unix; + hasunix; + { + bytecode; + }{ + native; + } *) let try_ext cmd = diff --git a/testsuite/tests/parallel/tak.ml b/testsuite/tests/parallel/tak.ml index a9b6874c4f..85bccf4007 100644 --- a/testsuite/tests/parallel/tak.ml +++ b/testsuite/tests/parallel/tak.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) (* filling minor heaps in parallel to trigger minor heap exhaustion codepath organically *) diff --git a/testsuite/tests/parallel/test_c_thread_register.ml b/testsuite/tests/parallel/test_c_thread_register.ml index 352424a377..71af40f146 100644 --- a/testsuite/tests/parallel/test_c_thread_register.ml +++ b/testsuite/tests/parallel/test_c_thread_register.ml @@ -1,9 +1,12 @@ (* TEST - modules = "test_c_thread_register_cstubs.c" - * hassysthreads - include systhreads - ** bytecode - ** native + modules = "test_c_thread_register_cstubs.c"; + include systhreads; + hassysthreads; + { + bytecode; + }{ + native; + } *) (* spins a external thread from C and register it to the OCaml runtime *) diff --git a/testsuite/tests/parallel/test_issue_11094.ml b/testsuite/tests/parallel/test_issue_11094.ml index ffc6d4bedd..b2e2411767 100644 --- a/testsuite/tests/parallel/test_issue_11094.ml +++ b/testsuite/tests/parallel/test_issue_11094.ml @@ -1,6 +1,9 @@ (* TEST -* bytecode -* native + { + bytecode; + }{ + native; + } *) open Effect diff --git a/testsuite/tests/parse-errors/escape_error.ml b/testsuite/tests/parse-errors/escape_error.ml index 2a8e99b61d..4206123f6c 100644 --- a/testsuite/tests/parse-errors/escape_error.ml +++ b/testsuite/tests/parse-errors/escape_error.ml @@ -1,5 +1,5 @@ -(* TEST - * toplevel +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) *) (* Nothing to see here, parse.ml dictates that these be printed as regular @@ -10,3 +10,7 @@ try foo () with ;; (3 : );; (3 :> );; + +(* TEST + toplevel; +*) diff --git a/testsuite/tests/parse-errors/expecting.ml b/testsuite/tests/parse-errors/expecting.ml index 4298b81868..5f3026b342 100644 --- a/testsuite/tests/parse-errors/expecting.ml +++ b/testsuite/tests/parse-errors/expecting.ml @@ -1,5 +1,5 @@ -(* TEST - * toplevel +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) *) let f = function @@ -33,3 +33,7 @@ let f = function let f = function | (module -> () ;; + +(* TEST + toplevel; +*) diff --git a/testsuite/tests/parse-errors/mismatch_struct_sig.ml b/testsuite/tests/parse-errors/mismatch_struct_sig.ml index 827adb6aff..d22a45a8cb 100644 --- a/testsuite/tests/parse-errors/mismatch_struct_sig.ml +++ b/testsuite/tests/parse-errors/mismatch_struct_sig.ml @@ -1,5 +1,5 @@ -(* TEST - * toplevel +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) *) module type S = struct end @@ -38,3 +38,7 @@ module type S = sig include module type of sig end end ;; + +(* TEST + toplevel; +*) diff --git a/testsuite/tests/parse-errors/pr7847.ml b/testsuite/tests/parse-errors/pr7847.ml index 8018109b1e..6c2e9fd531 100644 --- a/testsuite/tests/parse-errors/pr7847.ml +++ b/testsuite/tests/parse-errors/pr7847.ml @@ -1,10 +1,17 @@ -(* TEST -* setup-ocamlc.byte-build-env -** ocamlc.byte -ocamlc_byte_exit_status = "2" -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + *) (* https://caml.inria.fr/mantis/view.php?id=7847 The backquote causes a syntax error; this file should be rejected. *) external x : unit -> (int,int)`A.t = "x" + +(* TEST + setup-ocamlc.byte-build-env; + ocamlc_byte_exit_status = "2"; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/parse-errors/unclosed_class_signature.mli b/testsuite/tests/parse-errors/unclosed_class_signature.mli index 0aa6bf494e..659c8b9a48 100644 --- a/testsuite/tests/parse-errors/unclosed_class_signature.mli +++ b/testsuite/tests/parse-errors/unclosed_class_signature.mli @@ -1,8 +1,8 @@ (* TEST -* setup-ocamlc.byte-build-env -** ocamlc.byte -ocamlc_byte_exit_status = "2" -*** check-ocamlc.byte-output + setup-ocamlc.byte-build-env; + ocamlc_byte_exit_status = "2"; + ocamlc.byte; + check-ocamlc.byte-output; *) (* It is apparently impossible to get the "unclosed object" message. *) diff --git a/testsuite/tests/parse-errors/unclosed_class_simpl_expr1.ml b/testsuite/tests/parse-errors/unclosed_class_simpl_expr1.ml index 86466d8155..d0bc47ba96 100644 --- a/testsuite/tests/parse-errors/unclosed_class_simpl_expr1.ml +++ b/testsuite/tests/parse-errors/unclosed_class_simpl_expr1.ml @@ -1,8 +1,8 @@ (* TEST -* setup-ocamlc.byte-build-env -** ocamlc.byte -ocamlc_byte_exit_status = "2" -*** check-ocamlc.byte-output + setup-ocamlc.byte-build-env; + ocamlc_byte_exit_status = "2"; + ocamlc.byte; + check-ocamlc.byte-output; *) class c = object diff --git a/testsuite/tests/parse-errors/unclosed_class_simpl_expr2.ml b/testsuite/tests/parse-errors/unclosed_class_simpl_expr2.ml index dc762fd252..edb21933f2 100644 --- a/testsuite/tests/parse-errors/unclosed_class_simpl_expr2.ml +++ b/testsuite/tests/parse-errors/unclosed_class_simpl_expr2.ml @@ -1,8 +1,8 @@ (* TEST -* setup-ocamlc.byte-build-env -** ocamlc.byte -ocamlc_byte_exit_status = "2" -*** check-ocamlc.byte-output + setup-ocamlc.byte-build-env; + ocamlc_byte_exit_status = "2"; + ocamlc.byte; + check-ocamlc.byte-output; *) class c = (object end : object end diff --git a/testsuite/tests/parse-errors/unclosed_class_simpl_expr3.ml b/testsuite/tests/parse-errors/unclosed_class_simpl_expr3.ml index 142d3b09e0..3b689293cf 100644 --- a/testsuite/tests/parse-errors/unclosed_class_simpl_expr3.ml +++ b/testsuite/tests/parse-errors/unclosed_class_simpl_expr3.ml @@ -1,8 +1,8 @@ (* TEST -* setup-ocamlc.byte-build-env -** ocamlc.byte -ocamlc_byte_exit_status = "2" -*** check-ocamlc.byte-output + setup-ocamlc.byte-build-env; + ocamlc_byte_exit_status = "2"; + ocamlc.byte; + check-ocamlc.byte-output; *) class c = (object end diff --git a/testsuite/tests/parse-errors/unclosed_object.ml b/testsuite/tests/parse-errors/unclosed_object.ml index c74a71357c..6528ea09f8 100644 --- a/testsuite/tests/parse-errors/unclosed_object.ml +++ b/testsuite/tests/parse-errors/unclosed_object.ml @@ -1,8 +1,8 @@ (* TEST -* setup-ocamlc.byte-build-env -** ocamlc.byte -ocamlc_byte_exit_status = "2" -*** check-ocamlc.byte-output + setup-ocamlc.byte-build-env; + ocamlc_byte_exit_status = "2"; + ocamlc.byte; + check-ocamlc.byte-output; *) (* Failed to get the unclosed object error message. *) diff --git a/testsuite/tests/parse-errors/unclosed_paren_module_expr1.ml b/testsuite/tests/parse-errors/unclosed_paren_module_expr1.ml index b22a3fb4fb..259f2799a2 100644 --- a/testsuite/tests/parse-errors/unclosed_paren_module_expr1.ml +++ b/testsuite/tests/parse-errors/unclosed_paren_module_expr1.ml @@ -1,8 +1,8 @@ (* TEST -* setup-ocamlc.byte-build-env -** ocamlc.byte -ocamlc_byte_exit_status = "2" -*** check-ocamlc.byte-output + setup-ocamlc.byte-build-env; + ocamlc_byte_exit_status = "2"; + ocamlc.byte; + check-ocamlc.byte-output; *) module M = (struct end : sig end diff --git a/testsuite/tests/parse-errors/unclosed_paren_module_expr2.ml b/testsuite/tests/parse-errors/unclosed_paren_module_expr2.ml index a786f351b7..44ac330bc3 100644 --- a/testsuite/tests/parse-errors/unclosed_paren_module_expr2.ml +++ b/testsuite/tests/parse-errors/unclosed_paren_module_expr2.ml @@ -1,8 +1,8 @@ (* TEST -* setup-ocamlc.byte-build-env -** ocamlc.byte -ocamlc_byte_exit_status = "2" -*** check-ocamlc.byte-output + setup-ocamlc.byte-build-env; + ocamlc_byte_exit_status = "2"; + ocamlc.byte; + check-ocamlc.byte-output; *) module M = (struct end diff --git a/testsuite/tests/parse-errors/unclosed_paren_module_expr3.ml b/testsuite/tests/parse-errors/unclosed_paren_module_expr3.ml index 4c5c78585d..9cc8d6e6c5 100644 --- a/testsuite/tests/parse-errors/unclosed_paren_module_expr3.ml +++ b/testsuite/tests/parse-errors/unclosed_paren_module_expr3.ml @@ -1,8 +1,8 @@ (* TEST -* setup-ocamlc.byte-build-env -** ocamlc.byte -ocamlc_byte_exit_status = "2" -*** check-ocamlc.byte-output + setup-ocamlc.byte-build-env; + ocamlc_byte_exit_status = "2"; + ocamlc.byte; + check-ocamlc.byte-output; *) module M = (val 3 : diff --git a/testsuite/tests/parse-errors/unclosed_paren_module_expr4.ml b/testsuite/tests/parse-errors/unclosed_paren_module_expr4.ml index fc3daefcc3..075d5c599e 100644 --- a/testsuite/tests/parse-errors/unclosed_paren_module_expr4.ml +++ b/testsuite/tests/parse-errors/unclosed_paren_module_expr4.ml @@ -1,8 +1,8 @@ (* TEST -* setup-ocamlc.byte-build-env -** ocamlc.byte -ocamlc_byte_exit_status = "2" -*** check-ocamlc.byte-output + setup-ocamlc.byte-build-env; + ocamlc_byte_exit_status = "2"; + ocamlc.byte; + check-ocamlc.byte-output; *) module M = (val 3 :> diff --git a/testsuite/tests/parse-errors/unclosed_paren_module_expr5.ml b/testsuite/tests/parse-errors/unclosed_paren_module_expr5.ml index 8ce6c0b21c..68a044256d 100644 --- a/testsuite/tests/parse-errors/unclosed_paren_module_expr5.ml +++ b/testsuite/tests/parse-errors/unclosed_paren_module_expr5.ml @@ -1,8 +1,8 @@ (* TEST -* setup-ocamlc.byte-build-env -** ocamlc.byte -ocamlc_byte_exit_status = "2" -*** check-ocamlc.byte-output + setup-ocamlc.byte-build-env; + ocamlc_byte_exit_status = "2"; + ocamlc.byte; + check-ocamlc.byte-output; *) module M = (val 3 diff --git a/testsuite/tests/parse-errors/unclosed_paren_module_type.mli b/testsuite/tests/parse-errors/unclosed_paren_module_type.mli index 436ce5dc27..e428959842 100644 --- a/testsuite/tests/parse-errors/unclosed_paren_module_type.mli +++ b/testsuite/tests/parse-errors/unclosed_paren_module_type.mli @@ -1,8 +1,8 @@ (* TEST -* setup-ocamlc.byte-build-env -** ocamlc.byte -ocamlc_byte_exit_status = "2" -*** check-ocamlc.byte-output + setup-ocamlc.byte-build-env; + ocamlc_byte_exit_status = "2"; + ocamlc.byte; + check-ocamlc.byte-output; *) module M : (sig end diff --git a/testsuite/tests/parse-errors/unclosed_sig.mli b/testsuite/tests/parse-errors/unclosed_sig.mli index af49ea4079..12b4d3c975 100644 --- a/testsuite/tests/parse-errors/unclosed_sig.mli +++ b/testsuite/tests/parse-errors/unclosed_sig.mli @@ -1,8 +1,8 @@ (* TEST -* setup-ocamlc.byte-build-env -** ocamlc.byte -ocamlc_byte_exit_status = "2" -*** check-ocamlc.byte-output + setup-ocamlc.byte-build-env; + ocamlc_byte_exit_status = "2"; + ocamlc.byte; + check-ocamlc.byte-output; *) module M : sig diff --git a/testsuite/tests/parse-errors/unclosed_simple_expr.ml b/testsuite/tests/parse-errors/unclosed_simple_expr.ml index f5a9e3b7f2..3a94e4cee8 100644 --- a/testsuite/tests/parse-errors/unclosed_simple_expr.ml +++ b/testsuite/tests/parse-errors/unclosed_simple_expr.ml @@ -1,5 +1,5 @@ (* TEST - * toplevel + toplevel; *) (3; 2;; diff --git a/testsuite/tests/parse-errors/unclosed_simple_pattern.ml b/testsuite/tests/parse-errors/unclosed_simple_pattern.ml index f0878848bb..4c4c052e2c 100644 --- a/testsuite/tests/parse-errors/unclosed_simple_pattern.ml +++ b/testsuite/tests/parse-errors/unclosed_simple_pattern.ml @@ -1,5 +1,5 @@ (* TEST - * toplevel + toplevel; *) let f = function diff --git a/testsuite/tests/parse-errors/unclosed_struct.ml b/testsuite/tests/parse-errors/unclosed_struct.ml index 6066f1e826..5b05335e73 100644 --- a/testsuite/tests/parse-errors/unclosed_struct.ml +++ b/testsuite/tests/parse-errors/unclosed_struct.ml @@ -1,8 +1,8 @@ (* TEST -* setup-ocamlc.byte-build-env -** ocamlc.byte -ocamlc_byte_exit_status = "2" -*** check-ocamlc.byte-output + setup-ocamlc.byte-build-env; + ocamlc_byte_exit_status = "2"; + ocamlc.byte; + check-ocamlc.byte-output; *) module M = struct diff --git a/testsuite/tests/parsetree/locations_test.ml b/testsuite/tests/parsetree/locations_test.ml index e295d9a4ca..e423d99980 100644 --- a/testsuite/tests/parsetree/locations_test.ml +++ b/testsuite/tests/parsetree/locations_test.ml @@ -1,6 +1,6 @@ -(* TEST - flags = "-dparsetree" - * toplevel *) +(* TEST_BELOW +Filler_text_added_ +to_preserve_lo*) (* Using a toplevel test and not an expect test, because the locs get shifted by the expect blocks and the output is therefore not stable. *) @@ -132,3 +132,8 @@ let g y = let f ~y = y + 1 in f ~(y:int) ;; + +(* TEST + flags = "-dparsetree"; + toplevel; +*) diff --git a/testsuite/tests/parsetree/test.ml b/testsuite/tests/parsetree/test.ml index a75fa27731..119783e77d 100644 --- a/testsuite/tests/parsetree/test.ml +++ b/testsuite/tests/parsetree/test.ml @@ -1,6 +1,6 @@ (* TEST - include ocamlcommon - readonly_files = "source.ml" + include ocamlcommon; + readonly_files = "source.ml"; *) (* (c) Alain Frisch / Lexifi *) diff --git a/testsuite/tests/parsing/anonymous_class_parameter.ml b/testsuite/tests/parsing/anonymous_class_parameter.ml index bbecc1272b..d2a9fed478 100644 --- a/testsuite/tests/parsing/anonymous_class_parameter.ml +++ b/testsuite/tests/parsing/anonymous_class_parameter.ml @@ -1,8 +1,8 @@ (* TEST - flags = "-i" - * setup-ocamlc.byte-build-env - ** ocamlc.byte - *** check-ocamlc.byte-output + flags = "-i"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) (* This test is valid OCaml code. diff --git a/testsuite/tests/parsing/arrow_ambiguity.ml b/testsuite/tests/parsing/arrow_ambiguity.ml index 5af88afe2b..a40b7b5d30 100644 --- a/testsuite/tests/parsing/arrow_ambiguity.ml +++ b/testsuite/tests/parsing/arrow_ambiguity.ml @@ -1,8 +1,8 @@ (* TEST - ocamlc_byte_exit_status = "2" - * setup-ocamlc.byte-build-env - ** ocamlc.byte - *** check-ocamlc.byte-output + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) (* A potential ambiguity arises because the arrow -> is used diff --git a/testsuite/tests/parsing/assert_location.ml b/testsuite/tests/parsing/assert_location.ml index dc8c6b47ca..58a79aeec0 100644 --- a/testsuite/tests/parsing/assert_location.ml +++ b/testsuite/tests/parsing/assert_location.ml @@ -1,7 +1,11 @@ -(* TEST - exit_status = "2" +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) *) let () = ( assert false ) + +(* TEST + exit_status = "2"; +*) diff --git a/testsuite/tests/parsing/attributes.ml b/testsuite/tests/parsing/attributes.ml index 14a00083e6..81caf0f820 100644 --- a/testsuite/tests/parsing/attributes.ml +++ b/testsuite/tests/parsing/attributes.ml @@ -1,8 +1,8 @@ -(* TEST - flags = "-dparsetree" - * setup-ocamlc.byte-build-env - ** ocamlc.byte - *** check-ocamlc.byte-output +(* TEST_BELOW +Filler_text_added_ +to_preserve_locations_while_tran +slating_from_old_ +syntax__Filler_text_added_to_pr *) exception Foo [@foo] [@@foo] @@ -55,3 +55,10 @@ module _ = (Int : T with type t = int [@foo]) let _ = (module Int : T [@foo]) let _ = (module Int : T with type t = int [@foo]) + +(* TEST + flags = "-dparsetree"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/parsing/broken_invariants.ml b/testsuite/tests/parsing/broken_invariants.ml index 29e09a191c..24e27a6a6c 100644 --- a/testsuite/tests/parsing/broken_invariants.ml +++ b/testsuite/tests/parsing/broken_invariants.ml @@ -1,12 +1,12 @@ -(* TEST - readonly_files = "illegal_ppx.ml" - * setup-ocamlc.byte-build-env - ** ocamlc.byte with ocamlcommon - all_modules="illegal_ppx.ml" - program="ppx.exe" - *** toplevel - all_modules="broken_invariants.ml" - flags="-ppx '${ocamlrun} ${test_build_directory_prefix}/ocamlc.byte/ppx.exe'" +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + + + + *) let empty_tuple = [%tuple];; @@ -18,3 +18,14 @@ let f = function [%record_with_functor_fields] -> ();; module type s = sig [%%missing_rhs] end;; + +(* TEST + readonly_files = "illegal_ppx.ml"; + setup-ocamlc.byte-build-env; + all_modules = "illegal_ppx.ml"; + program = "ppx.exe"; + ocamlc.byte with ocamlcommon; + all_modules = "broken_invariants.ml"; + flags = "-ppx '${ocamlrun} ${test_build_directory_prefix}/ocamlc.byte/ppx.exe'"; + toplevel; +*) diff --git a/testsuite/tests/parsing/change_start_loc.ml b/testsuite/tests/parsing/change_start_loc.ml index 2e5604ce78..5ebe2bd770 100644 --- a/testsuite/tests/parsing/change_start_loc.ml +++ b/testsuite/tests/parsing/change_start_loc.ml @@ -1,6 +1,6 @@ (* TEST -flags = "-I ${ocamlsrcdir}/parsing -I ${ocamlsrcdir}/toplevel" -include ocamlcommon + flags = "-I ${ocamlsrcdir}/parsing -I ${ocamlsrcdir}/toplevel"; + include ocamlcommon; *) let position = Lexing.{ (* This corresponds to File "file.ml", line 100, character 10 *) pos_fname = "------should not appear------"; diff --git a/testsuite/tests/parsing/constructor_declarations.ml b/testsuite/tests/parsing/constructor_declarations.ml index cac1f1b0d7..0681a567f7 100644 --- a/testsuite/tests/parsing/constructor_declarations.ml +++ b/testsuite/tests/parsing/constructor_declarations.ml @@ -1,8 +1,8 @@ -(* TEST - ocamlc_byte_exit_status = "2" - * setup-ocamlc.byte-build-env - ** ocamlc.byte - *** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + *) (* Allowed. *) @@ -23,3 +23,10 @@ type w = | | A of int | B of bool + +(* TEST + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/parsing/docstrings.ml b/testsuite/tests/parsing/docstrings.ml index 401fbd3502..cf5a82f359 100644 --- a/testsuite/tests/parsing/docstrings.ml +++ b/testsuite/tests/parsing/docstrings.ml @@ -1,6 +1,6 @@ (* TEST - * expect - flags += " -dsource " + flags += " -dsource "; + expect; *) (***********************************************************************) diff --git a/testsuite/tests/parsing/extended_indexoperators.ml b/testsuite/tests/parsing/extended_indexoperators.ml index bb5fec23b1..348a500606 100644 --- a/testsuite/tests/parsing/extended_indexoperators.ml +++ b/testsuite/tests/parsing/extended_indexoperators.ml @@ -1,6 +1,6 @@ (* TEST - * expect - flags = "-dsource" + flags = "-dsource"; + expect; *) let (.?[]) = Hashtbl.find_opt diff --git a/testsuite/tests/parsing/extension_operators.ml b/testsuite/tests/parsing/extension_operators.ml index 683ec5952b..e13330399d 100644 --- a/testsuite/tests/parsing/extension_operators.ml +++ b/testsuite/tests/parsing/extension_operators.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) let f o x = o##x;; diff --git a/testsuite/tests/parsing/extensions.ml b/testsuite/tests/parsing/extensions.ml index 326d2a4768..b42570c012 100644 --- a/testsuite/tests/parsing/extensions.ml +++ b/testsuite/tests/parsing/extensions.ml @@ -1,9 +1,9 @@ -(* TEST - flags = "-dparsetree" - ocamlc_byte_exit_status = "2" - * setup-ocamlc.byte-build-env - ** ocamlc.byte - *** check-ocamlc.byte-output +(* TEST_BELOW +Filler_text_added_ +to_preserve_locations_while_tran +slating_from_old_syntax__Filler_ +text_added_to_pre +serve_locations_while_translati *) [%%foo let x = 1 in x] @@ -23,3 +23,11 @@ let [%foo? (Bar x | Baz x) ] : [%foo? #bar ] = [%foo? { x }] let [%foo: include S with type t = t ] : [%foo: val x : t val y : t] = [%foo: type t = t ] + +(* TEST + flags = "-dparsetree"; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/parsing/hash_ambiguity.ml b/testsuite/tests/parsing/hash_ambiguity.ml index 32f8297f5e..f364fac99a 100644 --- a/testsuite/tests/parsing/hash_ambiguity.ml +++ b/testsuite/tests/parsing/hash_ambiguity.ml @@ -1,8 +1,8 @@ -(* TEST - flags = "-stop-after parsing -dparsetree" - * setup-ocamlc.byte-build-env - ** ocamlc.byte - *** check-ocamlc.byte-output +(* TEST_BELOW +Filler_text_added_to_preserve_location +s_while_translating_from_old_syn +tax__Filler_text_ +added_to_preserve_locations_whi *) class ['a] list = object end @@ -15,3 +15,10 @@ type 'a t = int #list as 'a type 'a u = A of int #list type 'a v = A of int * int #list + +(* TEST + flags = "-stop-after parsing -dparsetree"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/parsing/int_and_float_with_modifier.ml b/testsuite/tests/parsing/int_and_float_with_modifier.ml index 444964be85..5c4de59212 100644 --- a/testsuite/tests/parsing/int_and_float_with_modifier.ml +++ b/testsuite/tests/parsing/int_and_float_with_modifier.ml @@ -1,9 +1,9 @@ -(* TEST - flags = "-dparsetree" - ocamlc_byte_exit_status = "2" - * setup-ocamlc.byte-build-env - ** ocamlc.byte - *** check-ocamlc.byte-output +(* TEST_BELOW +Filler_text_added_ +to_preserve_locations_while_tran +slating_from_old_syntax__Filler_ +text_added_to_pre +serve_locations_while_translati *) let int_with_custom_modifier = @@ -20,3 +20,11 @@ let hex_with_modifier = 0x32g let float_without_modifer = 1.2e3 let float_with_modifer = 1.2g + +(* TEST + flags = "-dparsetree"; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/parsing/multi_indices.ml b/testsuite/tests/parsing/multi_indices.ml index 8b67bd91e6..02ef1c944c 100644 --- a/testsuite/tests/parsing/multi_indices.ml +++ b/testsuite/tests/parsing/multi_indices.ml @@ -1,6 +1,6 @@ (* TEST - flags = "-dsource" - * expect + flags = "-dsource"; + expect; *) module A = Bigarray.Genarray diff --git a/testsuite/tests/parsing/pr10468.ml b/testsuite/tests/parsing/pr10468.ml index d795b3bf0f..b03bca7955 100644 --- a/testsuite/tests/parsing/pr10468.ml +++ b/testsuite/tests/parsing/pr10468.ml @@ -1,6 +1,6 @@ (* TEST - flags = "-dsource" - * expect + flags = "-dsource"; + expect; *) module type S = sig diff --git a/testsuite/tests/parsing/pr6604.ml b/testsuite/tests/parsing/pr6604.ml index 806f9c37ed..56150f06a1 100644 --- a/testsuite/tests/parsing/pr6604.ml +++ b/testsuite/tests/parsing/pr6604.ml @@ -1,9 +1,17 @@ -(* TEST - flags = "-dparsetree" - ocamlc_byte_exit_status = "2" - * setup-ocamlc.byte-build-env - ** ocamlc.byte - *** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) #1 + +(* TEST + flags = "-dparsetree"; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/parsing/pr6604_2.ml b/testsuite/tests/parsing/pr6604_2.ml index 995e242d33..a1287bd128 100644 --- a/testsuite/tests/parsing/pr6604_2.ml +++ b/testsuite/tests/parsing/pr6604_2.ml @@ -1,9 +1,17 @@ -(* TEST - flags = "-dparsetree" - ocamlc_byte_exit_status = "2" - * setup-ocamlc.byte-build-env - ** ocamlc.byte - *** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) #1 "pr6604.ml" + +(* TEST + flags = "-dparsetree"; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/parsing/pr6604_3.ml b/testsuite/tests/parsing/pr6604_3.ml index ef15c5c068..c8fc095dd6 100644 --- a/testsuite/tests/parsing/pr6604_3.ml +++ b/testsuite/tests/parsing/pr6604_3.ml @@ -1,8 +1,8 @@ (* TEST - flags = "-dparsetree" - * setup-ocamlc.byte-build-env - ** ocamlc.byte - *** check-ocamlc.byte-output + flags = "-dparsetree"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) # 1 "pr6604.ml" diff --git a/testsuite/tests/parsing/pr6865.ml b/testsuite/tests/parsing/pr6865.ml index c673e2a613..9e98315b0b 100644 --- a/testsuite/tests/parsing/pr6865.ml +++ b/testsuite/tests/parsing/pr6865.ml @@ -1,11 +1,19 @@ -(* TEST - flags = "-dparsetree" - ocamlc_byte_exit_status = "2" - * setup-ocamlc.byte-build-env - ** ocamlc.byte - *** check-ocamlc.byte-output +(* TEST_BELOW +Filler_text_added_ +to_preserve_locations_while_tran +slating_from_old_syntax__Filler_ +text_added_to_pre +serve_locations_while_translati *) let%foo x = 42 let%foo _ = () and _ = () let%foo _ = () + +(* TEST + flags = "-dparsetree"; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/parsing/pr7165.ml b/testsuite/tests/parsing/pr7165.ml index e25708c1fc..2e189f09c8 100644 --- a/testsuite/tests/parsing/pr7165.ml +++ b/testsuite/tests/parsing/pr7165.ml @@ -1,12 +1,20 @@ -(* TEST - flags = "-dparsetree" - ocamlc_byte_exit_status = "2" - * setup-ocamlc.byte-build-env - ** ocamlc.byte - *** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) (* this is a lexer directive with an out-of-bound integer; it should result in a lexing error instead of an uncaught exception as in PR#7165 *) #9342101923012312312 "" + +(* TEST + flags = "-dparsetree"; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/parsing/quotedextensions.ml b/testsuite/tests/parsing/quotedextensions.ml index f725f5a1a9..7389289491 100644 --- a/testsuite/tests/parsing/quotedextensions.ml +++ b/testsuite/tests/parsing/quotedextensions.ml @@ -1,9 +1,9 @@ -(* TEST - flags = "-dparsetree" - ocamlc_byte_exit_status = "2" - * setup-ocamlc.byte-build-env - ** ocamlc.byte - *** check-ocamlc.byte-output +(* TEST_BELOW +Filler_text_added_ +to_preserve_locations_while_tran +slating_from_old_syntax__Filler_ +text_added_to_pre +serve_locations_while_translati *) (* Structures *) @@ -40,3 +40,11 @@ let {%M.foo bar| <hello>{|x|} |bar} (* {|*)|}, and *) (* [%foo {bar|*)|bar}], and *) (* {%foo bar|*)|bar} should be valid inside comments *) + +(* TEST + flags = "-dparsetree"; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/parsing/reloc.ml b/testsuite/tests/parsing/reloc.ml index 0948d171b4..816456ee7c 100644 --- a/testsuite/tests/parsing/reloc.ml +++ b/testsuite/tests/parsing/reloc.ml @@ -1,7 +1,7 @@ (* TEST - flags = "-I ${ocamlsrcdir}/parsing -I ${ocamlsrcdir}/toplevel" - include ocamlcommon - * expect + flags = "-I ${ocamlsrcdir}/parsing -I ${ocamlsrcdir}/toplevel"; + include ocamlcommon; + expect; *) (* Check that [e.pexp_loc :: e.pexp_loc_stack] includes all diff --git a/testsuite/tests/parsing/shortcut_ext_attr.ml b/testsuite/tests/parsing/shortcut_ext_attr.ml index 222e7a0c97..133d7d1629 100644 --- a/testsuite/tests/parsing/shortcut_ext_attr.ml +++ b/testsuite/tests/parsing/shortcut_ext_attr.ml @@ -1,9 +1,9 @@ -(* TEST - flags = "-dparsetree" - ocamlc_byte_exit_status = "2" - * setup-ocamlc.byte-build-env - ** ocamlc.byte - *** check-ocamlc.byte-output +(* TEST_BELOW +Filler_text_added_ +to_preserve_locations_while_tran +slating_from_old_syntax__Filler_ +text_added_to_pre +serve_locations_while_translati *) (* Expressions *) let () = @@ -118,3 +118,11 @@ module type S = sig class type%foo[@foo] x = x end + +(* TEST + flags = "-dparsetree"; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/ppx-attributes/inline.ml b/testsuite/tests/ppx-attributes/inline.ml index cec8c7cf66..18fc3a6587 100644 --- a/testsuite/tests/ppx-attributes/inline.ml +++ b/testsuite/tests/ppx-attributes/inline.ml @@ -1,6 +1,6 @@ (* TEST - flags = "-dlambda -dno-unique-ids" - * expect + flags = "-dlambda -dno-unique-ids"; + expect; *) (* This checks that function attributes like [@inline] aren't dropped when they diff --git a/testsuite/tests/ppx-attributes/warning.ml b/testsuite/tests/ppx-attributes/warning.ml index 0ae6667472..a8c222f2ae 100644 --- a/testsuite/tests/ppx-attributes/warning.ml +++ b/testsuite/tests/ppx-attributes/warning.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) [@@@ocaml.warning "@A"] [@@@ocaml.alert "++all"] diff --git a/testsuite/tests/ppx-contexts/test.ml b/testsuite/tests/ppx-contexts/test.ml index a8b0be1fa4..558de98748 100644 --- a/testsuite/tests/ppx-contexts/test.ml +++ b/testsuite/tests/ppx-contexts/test.ml @@ -1,27 +1,17 @@ (* TEST -readonly_files = "myppx.ml" -include ocamlcommon -* setup-ocamlc.byte-build-env -** ocamlc.byte -program = "${test_build_directory}/myppx.exe" -all_modules = "myppx.ml" -*** ocamlc.byte -module = "test.ml" -flags = "-thread \ - -I ${test_build_directory} \ - -open List \ - -rectypes \ - -principal \ - -alias-deps \ - -unboxed-types \ - -ppx ${program}" -**** ocamlc.byte -module = "test.ml" -flags = "-g \ - -no-alias-deps \ - -no-unboxed-types \ - -ppx ${program}" -***** check-ocamlc.byte-output + readonly_files = "myppx.ml"; + include ocamlcommon; + setup-ocamlc.byte-build-env; + program = "${test_build_directory}/myppx.exe"; + all_modules = "myppx.ml"; + ocamlc.byte; + module = "test.ml"; + flags = "-thread -I ${test_build_directory} -open List -rectypes -principal -alias-deps -unboxed-types -ppx ${program}"; + ocamlc.byte; + module = "test.ml"; + flags = "-g -no-alias-deps -no-unboxed-types -ppx ${program}"; + ocamlc.byte; + check-ocamlc.byte-output; *) (* empty *) diff --git a/testsuite/tests/prim-bigstring/bigstring_access.ml b/testsuite/tests/prim-bigstring/bigstring_access.ml index 0014de3dda..9f550b7ffa 100644 --- a/testsuite/tests/prim-bigstring/bigstring_access.ml +++ b/testsuite/tests/prim-bigstring/bigstring_access.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) open Bigarray type bigstring = (char, int8_unsigned_elt, c_layout) Array1.t diff --git a/testsuite/tests/prim-bigstring/string_access.ml b/testsuite/tests/prim-bigstring/string_access.ml index 82c32f2f30..a37b9e9319 100644 --- a/testsuite/tests/prim-bigstring/string_access.ml +++ b/testsuite/tests/prim-bigstring/string_access.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) external caml_bytes_get_16 : bytes -> int -> int = "%caml_bytes_get16" external caml_bytes_get_32 : bytes -> int -> int32 = "%caml_bytes_get32" diff --git a/testsuite/tests/prim-bswap/bswap.ml b/testsuite/tests/prim-bswap/bswap.ml index 7ab822c74b..cf43908bcb 100644 --- a/testsuite/tests/prim-bswap/bswap.ml +++ b/testsuite/tests/prim-bswap/bswap.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) open Printf diff --git a/testsuite/tests/prim-revapply/apply.ml b/testsuite/tests/prim-revapply/apply.ml index 685b326344..8b557e152f 100644 --- a/testsuite/tests/prim-revapply/apply.ml +++ b/testsuite/tests/prim-revapply/apply.ml @@ -1,5 +1,5 @@ (* TEST - flags="-w +48" + flags = "-w +48"; *) external ( @@ ) : ('a -> 'b) -> 'a -> 'b = "%apply" diff --git a/testsuite/tests/prim-revapply/revapply.ml b/testsuite/tests/prim-revapply/revapply.ml index f65b109da5..341548c2eb 100644 --- a/testsuite/tests/prim-revapply/revapply.ml +++ b/testsuite/tests/prim-revapply/revapply.ml @@ -1,5 +1,5 @@ (* TEST - flags="-w +48" + flags = "-w +48"; *) external ( |> ) : 'a -> ('a -> 'b) -> 'b = "%revapply" diff --git a/testsuite/tests/printing-types/disambiguation.ml b/testsuite/tests/printing-types/disambiguation.ml index 12e244ec55..029076dcfd 100644 --- a/testsuite/tests/printing-types/disambiguation.ml +++ b/testsuite/tests/printing-types/disambiguation.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type 'a x = private [> `x] as 'a;; diff --git a/testsuite/tests/printing-types/pr248.ml b/testsuite/tests/printing-types/pr248.ml index 25d397260a..cad30c3805 100644 --- a/testsuite/tests/printing-types/pr248.ml +++ b/testsuite/tests/printing-types/pr248.ml @@ -1,5 +1,5 @@ (* TEST - * toplevel + toplevel; *) (** Test that weak variables keep their names long enough *) diff --git a/testsuite/tests/raise-counts/main.ml b/testsuite/tests/raise-counts/main.ml index b881b83280..cee4d34e4b 100644 --- a/testsuite/tests/raise-counts/main.ml +++ b/testsuite/tests/raise-counts/main.ml @@ -1,5 +1,5 @@ (* TEST - modules = "a.ml b.ml" + modules = "a.ml b.ml"; *) (* PR#7702 *) diff --git a/testsuite/tests/regression/gpr1623/gpr1623.ml b/testsuite/tests/regression/gpr1623/gpr1623.ml index 80f844524d..51f5720352 100644 --- a/testsuite/tests/regression/gpr1623/gpr1623.ml +++ b/testsuite/tests/regression/gpr1623/gpr1623.ml @@ -1,6 +1,6 @@ (* TEST - arguments = "???" - *) + arguments = "???"; +*) (* On Windows the runtime expand windows wildcards (asterisks and * question marks). diff --git a/testsuite/tests/regression/missing_set_of_closures/missing_set_of_closures.ml b/testsuite/tests/regression/missing_set_of_closures/missing_set_of_closures.ml index c71250cdb2..6f4aa12589 100644 --- a/testsuite/tests/regression/missing_set_of_closures/missing_set_of_closures.ml +++ b/testsuite/tests/regression/missing_set_of_closures/missing_set_of_closures.ml @@ -1,20 +1,20 @@ (* TEST -readonly_files = "a.ml b.ml b2.ml" -subdirectories = "dir" -* setup-ocamlopt.byte-build-env -** ocamlopt.byte -module = "a.ml" -*** ocamlopt.byte -module = "b.ml" -**** ocamlopt.byte -module = "b2.ml" -***** copy -src = "b.cmx b.cmi b2.cmx b2.cmi" -dst = "dir/" -****** cd -cwd = "dir" -******* ocamlopt.byte -module = "c.ml" -flags = "-w -58" -******** check-ocamlopt.byte-output + readonly_files = "a.ml b.ml b2.ml"; + subdirectories = "dir"; + setup-ocamlopt.byte-build-env; + module = "a.ml"; + ocamlopt.byte; + module = "b.ml"; + ocamlopt.byte; + module = "b2.ml"; + ocamlopt.byte; + src = "b.cmx b.cmi b2.cmx b2.cmi"; + dst = "dir/"; + copy; + cwd = "dir"; + cd; + module = "c.ml"; + flags = "-w -58"; + ocamlopt.byte; + check-ocamlopt.byte-output; *) diff --git a/testsuite/tests/regression/pr11887/pr11887.ml b/testsuite/tests/regression/pr11887/pr11887.ml index 9e7fc6da65..858ae3e2dc 100644 --- a/testsuite/tests/regression/pr11887/pr11887.ml +++ b/testsuite/tests/regression/pr11887/pr11887.ml @@ -1,6 +1,6 @@ (* TEST - * native - ocamlopt_flags = "-dcmm-invariants" + ocamlopt_flags = "-dcmm-invariants"; + native; *) module Constant = struct diff --git a/testsuite/tests/regression/pr3612/pr3612.ml b/testsuite/tests/regression/pr3612/pr3612.ml index c2ca8dbb7f..758011943a 100644 --- a/testsuite/tests/regression/pr3612/pr3612.ml +++ b/testsuite/tests/regression/pr3612/pr3612.ml @@ -1,5 +1,5 @@ (* TEST - modules = "custom_finalize.c" + modules = "custom_finalize.c"; *) type t diff --git a/testsuite/tests/regression/pr7798/pr7798.ml b/testsuite/tests/regression/pr7798/pr7798.ml index a91b4dc2fb..3f09de0768 100644 --- a/testsuite/tests/regression/pr7798/pr7798.ml +++ b/testsuite/tests/regression/pr7798/pr7798.ml @@ -1,8 +1,12 @@ (* TEST - * bytecode - * native - * native - ocamlopt_flags = "-compact" + { + bytecode; + }{ + native; + }{ + ocamlopt_flags = "-compact"; + native; + } *) type mut2 = { mutable p: int; mutable q:int } diff --git a/testsuite/tests/regression/pr8769/pr8769.ml b/testsuite/tests/regression/pr8769/pr8769.ml index fa0c73f7a4..e6e5c3b4dd 100644 --- a/testsuite/tests/regression/pr8769/pr8769.ml +++ b/testsuite/tests/regression/pr8769/pr8769.ml @@ -1,32 +1,42 @@ (* TEST -modules = "nocrypto.mli fortuna.ml rng.ml" - -* setup-ocamlc.byte-build-env -** ocamlc.byte -module = "nocrypto.mli" -** ocamlc.byte -flags = "-for-pack Nocrypto" -module = "fortuna.ml" -** ocamlc.byte -flags = "-for-pack Nocrypto" -module = "rng.ml" -** ocamlc.byte -program = "nocrypto.cmo" -flags = "-pack" -all_modules = "fortuna.cmo rng.cmo" - -* setup-ocamlopt.byte-build-env -** ocamlopt.byte -module = "nocrypto.mli" -** ocamlopt.byte -flags = "-for-pack Nocrypto" -module = "fortuna.ml" -** ocamlopt.byte -flags = "-for-pack Nocrypto" -module = "rng.ml" -** ocamlopt.byte -program = "nocrypto.cmx" -flags = "-pack" -all_modules = "fortuna.cmx rng.cmx" - + modules = "nocrypto.mli fortuna.ml rng.ml"; + { + setup-ocamlc.byte-build-env; + { + module = "nocrypto.mli"; + ocamlc.byte; + }{ + flags = "-for-pack Nocrypto"; + module = "fortuna.ml"; + ocamlc.byte; + }{ + flags = "-for-pack Nocrypto"; + module = "rng.ml"; + ocamlc.byte; + }{ + program = "nocrypto.cmo"; + flags = "-pack"; + all_modules = "fortuna.cmo rng.cmo"; + ocamlc.byte; + } + }{ + setup-ocamlopt.byte-build-env; + { + module = "nocrypto.mli"; + ocamlopt.byte; + }{ + flags = "-for-pack Nocrypto"; + module = "fortuna.ml"; + ocamlopt.byte; + }{ + flags = "-for-pack Nocrypto"; + module = "rng.ml"; + ocamlopt.byte; + }{ + program = "nocrypto.cmx"; + flags = "-pack"; + all_modules = "fortuna.cmx rng.cmx"; + ocamlopt.byte; + } + } *) diff --git a/testsuite/tests/regression/pr9326/gc_set.ml b/testsuite/tests/regression/pr9326/gc_set.ml index 2570aec28e..e672e23c9d 100644 --- a/testsuite/tests/regression/pr9326/gc_set.ml +++ b/testsuite/tests/regression/pr9326/gc_set.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) open Gc diff --git a/testsuite/tests/reproducibility/cmis_on_file_system.ml b/testsuite/tests/reproducibility/cmis_on_file_system.ml index d82f1b378a..25c4857ce0 100644 --- a/testsuite/tests/reproducibility/cmis_on_file_system.ml +++ b/testsuite/tests/reproducibility/cmis_on_file_system.ml @@ -1,22 +1,22 @@ (* TEST - readonly_files = "cmis_on_file_system.ml cmis_on_file_system_companion.mli" - * setup-ocamlc.byte-build-env - ** ocamlc.byte - compile_only = "true" - module = "cmis_on_file_system.ml" - flags="-bin-annot -no-alias-deps -w '-49'" - *** script - script= "mv cmis_on_file_system.cmt lone.cmt" - **** ocamlc.byte - module = "cmis_on_file_system_companion.mli" - compile_only="true" - ***** ocamlc.byte - compile_only = "true" - flags="-bin-annot -no-alias-deps -w '-49'" - module="cmis_on_file_system.ml" - ****** compare-binary-files - program="cmis_on_file_system.cmt" - program2="lone.cmt" + readonly_files = "cmis_on_file_system.ml cmis_on_file_system_companion.mli"; + setup-ocamlc.byte-build-env; + compile_only = "true"; + module = "cmis_on_file_system.ml"; + flags = "-bin-annot -no-alias-deps -w '-49'"; + ocamlc.byte; + script = "mv cmis_on_file_system.cmt lone.cmt"; + script; + module = "cmis_on_file_system_companion.mli"; + compile_only = "true"; + ocamlc.byte; + compile_only = "true"; + flags = "-bin-annot -no-alias-deps -w '-49'"; + module = "cmis_on_file_system.ml"; + ocamlc.byte; + program = "cmis_on_file_system.cmt"; + program2 = "lone.cmt"; + compare-binary-files; *) diff --git a/testsuite/tests/required-external/main.ml b/testsuite/tests/required-external/main.ml index 7764b822e9..c2c4bfb3d3 100644 --- a/testsuite/tests/required-external/main.ml +++ b/testsuite/tests/required-external/main.ml @@ -1,40 +1,40 @@ (* TEST -modules = "file.ml" - -* setup-ocamlc.byte-build-env -program = "${test_build_directory}/main.exe" -** ocamlc.byte -module = "file.ml" -*** ocamlc.byte -module = "" -program = "lib.cma" -flags = "-a" -all_modules = "file.cmo" -**** ocamlc.byte -program = "${test_build_directory}/main.exe" -all_modules = "lib.cma main.ml" -flags = "" -***** check-ocamlc.byte-output -****** run -******* check-program-output - -* setup-ocamlopt.byte-build-env -program = "${test_build_directory}/main.exe" -** ocamlopt.byte -module = "file.ml" -*** ocamlopt.byte -module = "" -program = "lib.cmxa" -flags = "-a" -all_modules = "file.cmx" -**** ocamlopt.byte -program = "${test_build_directory}/main.exe" -all_modules = "lib.cmxa main.ml" -flags = "" -***** check-ocamlopt.byte-output -****** run -******* check-program-output - + modules = "file.ml"; + { + program = "${test_build_directory}/main.exe"; + setup-ocamlc.byte-build-env; + module = "file.ml"; + ocamlc.byte; + module = ""; + program = "lib.cma"; + flags = "-a"; + all_modules = "file.cmo"; + ocamlc.byte; + program = "${test_build_directory}/main.exe"; + all_modules = "lib.cma main.ml"; + flags = ""; + ocamlc.byte; + check-ocamlc.byte-output; + run; + check-program-output; + }{ + program = "${test_build_directory}/main.exe"; + setup-ocamlopt.byte-build-env; + module = "file.ml"; + ocamlopt.byte; + module = ""; + program = "lib.cmxa"; + flags = "-a"; + all_modules = "file.cmx"; + ocamlopt.byte; + program = "${test_build_directory}/main.exe"; + all_modules = "lib.cmxa main.ml"; + flags = ""; + ocamlopt.byte; + check-ocamlopt.byte-output; + run; + check-program-output; + } *) let () = diff --git a/testsuite/tests/runtime-C-exceptions/test.ml b/testsuite/tests/runtime-C-exceptions/test.ml index 17bf425227..7bc2671889 100644 --- a/testsuite/tests/runtime-C-exceptions/test.ml +++ b/testsuite/tests/runtime-C-exceptions/test.ml @@ -1,5 +1,5 @@ (* TEST - modules = "stub_test.c" + modules = "stub_test.c"; *) external failwith_from_ocaml : string -> 'a = "caml_failwith_value" diff --git a/testsuite/tests/runtime-errors/stackoverflow.ml b/testsuite/tests/runtime-errors/stackoverflow.ml index b617e64cdc..7919f604f3 100644 --- a/testsuite/tests/runtime-errors/stackoverflow.ml +++ b/testsuite/tests/runtime-errors/stackoverflow.ml @@ -1,6 +1,6 @@ (* TEST -flags = "-w -a" -ocamlrunparam += "l=100000" + flags = "-w -a"; + ocamlrunparam += "l=100000"; *) let rec f x = diff --git a/testsuite/tests/runtime-errors/syserror.ml b/testsuite/tests/runtime-errors/syserror.ml index d5230ad7cf..5cab8e3bd5 100644 --- a/testsuite/tests/runtime-errors/syserror.ml +++ b/testsuite/tests/runtime-errors/syserror.ml @@ -1,29 +1,34 @@ (* TEST - -flags = "-w -a" - -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** run -exit_status = "2" -**** libunix -***** check-program-output -reference = "${test_source_directory}/syserror.unix.reference" -**** libwin32unix -***** check-program-output -reference = "${test_source_directory}/syserror.win32.reference" - -* setup-ocamlopt.byte-build-env -** ocamlopt.byte -*** run -exit_status = "2" -**** libunix -***** check-program-output -reference = "${test_source_directory}/syserror.unix.reference" -**** libwin32unix -***** check-program-output -reference = "${test_source_directory}/syserror.win32.reference" - + flags = "-w -a"; + { + setup-ocamlc.byte-build-env; + ocamlc.byte; + exit_status = "2"; + run; + { + libunix; + reference = "${test_source_directory}/syserror.unix.reference"; + check-program-output; + }{ + libwin32unix; + reference = "${test_source_directory}/syserror.win32.reference"; + check-program-output; + } + }{ + setup-ocamlopt.byte-build-env; + ocamlopt.byte; + exit_status = "2"; + run; + { + libunix; + reference = "${test_source_directory}/syserror.unix.reference"; + check-program-output; + }{ + libwin32unix; + reference = "${test_source_directory}/syserror.win32.reference"; + check-program-output; + } + } *) let _ = Printexc.record_backtrace false diff --git a/testsuite/tests/self-contained-toplevel/main.ml b/testsuite/tests/self-contained-toplevel/main.ml index 51d44e09cd..c3342b6b40 100644 --- a/testsuite/tests/self-contained-toplevel/main.ml +++ b/testsuite/tests/self-contained-toplevel/main.ml @@ -1,21 +1,21 @@ (* TEST -readonly_files = "foo.ml gen_cached_cmi.ml input.ml" -* setup-ocamlc.byte-build-env -** ocamlc.byte -module = "foo.ml" -*** ocaml with ocamlcommon -ocaml_script_as_argument = "true" -test_file = "gen_cached_cmi.ml" -arguments = "cached_cmi.ml" -**** ocamlc.byte -module = "" -program = "${test_build_directory}/main.exe" -libraries += "ocamlbytecomp ocamltoplevel" -all_modules = "foo.cmo cached_cmi.ml main.ml" -***** run -set OCAMLLIB="${ocamlsrcdir}/stdlib" -arguments = "input.ml" -****** check-program-output + readonly_files = "foo.ml gen_cached_cmi.ml input.ml"; + setup-ocamlc.byte-build-env; + module = "foo.ml"; + ocamlc.byte; + ocaml_script_as_argument = "true"; + test_file = "gen_cached_cmi.ml"; + arguments = "cached_cmi.ml"; + ocaml with ocamlcommon; + module = ""; + program = "${test_build_directory}/main.exe"; + libraries += "ocamlbytecomp ocamltoplevel"; + all_modules = "foo.cmo cached_cmi.ml main.ml"; + ocamlc.byte; + set OCAMLLIB = "${ocamlsrcdir}/stdlib"; + arguments = "input.ml"; + run; + check-program-output; *) let () = diff --git a/testsuite/tests/shadow_include/artificial.ml b/testsuite/tests/shadow_include/artificial.ml index f881c9994c..daed88f9f9 100644 --- a/testsuite/tests/shadow_include/artificial.ml +++ b/testsuite/tests/shadow_include/artificial.ml @@ -1,6 +1,6 @@ (* TEST - * expect - flags = "-nostdlib -nopervasives" + flags = "-nostdlib -nopervasives"; + expect; *) module Foo : sig diff --git a/testsuite/tests/shadow_include/cannot_shadow_error.ml b/testsuite/tests/shadow_include/cannot_shadow_error.ml index 11619ca833..0432f082a3 100644 --- a/testsuite/tests/shadow_include/cannot_shadow_error.ml +++ b/testsuite/tests/shadow_include/cannot_shadow_error.ml @@ -1,9 +1,9 @@ -(* TEST -* setup-ocamlc.byte-build-env -flags = "-nostdlib -nopervasives" -** ocamlc.byte -ocamlc_byte_exit_status = "2" -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) (* Same example as in tests/typing-sigsubst/sigsubst.ml, but not as an @@ -23,3 +23,11 @@ module type PrintableComparable = sig include Printable include Comparable with type t = t end + +(* TEST + flags = "-nostdlib -nopervasives"; + setup-ocamlc.byte-build-env; + ocamlc_byte_exit_status = "2"; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/shadow_include/ghosts.ml b/testsuite/tests/shadow_include/ghosts.ml index 09051a6561..48aa4c9276 100644 --- a/testsuite/tests/shadow_include/ghosts.ml +++ b/testsuite/tests/shadow_include/ghosts.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module C = struct diff --git a/testsuite/tests/shadow_include/shadow_all.ml b/testsuite/tests/shadow_include/shadow_all.ml index 5ff0d99c90..823f447ffe 100644 --- a/testsuite/tests/shadow_include/shadow_all.ml +++ b/testsuite/tests/shadow_include/shadow_all.ml @@ -1,6 +1,6 @@ (* TEST - * expect - flags = "-nopervasives" (* can't pass -nostdlib because of objects. *) + flags = "-nopervasives"; (* can't pass -nostdlib because of objects. *) + expect; *) (* Signatures *) diff --git a/testsuite/tests/shapes/comp_units.ml b/testsuite/tests/shapes/comp_units.ml index 3a1b9494a1..c4da2e8b85 100644 --- a/testsuite/tests/shapes/comp_units.ml +++ b/testsuite/tests/shapes/comp_units.ml @@ -1,6 +1,6 @@ (* TEST - flags = "-dshape" - * expect + flags = "-dshape"; + expect; *) (* Make sure that shapes of compilation units are never eagerly loaded, diff --git a/testsuite/tests/shapes/functors.ml b/testsuite/tests/shapes/functors.ml index 613e2fae88..fee5c96244 100644 --- a/testsuite/tests/shapes/functors.ml +++ b/testsuite/tests/shapes/functors.ml @@ -1,6 +1,6 @@ (* TEST - flags = "-dshape" - * expect + flags = "-dshape"; + expect; *) module type S = sig diff --git a/testsuite/tests/shapes/incl_md_typeof.ml b/testsuite/tests/shapes/incl_md_typeof.ml index 95b952ff38..b03b7ec673 100644 --- a/testsuite/tests/shapes/incl_md_typeof.ml +++ b/testsuite/tests/shapes/incl_md_typeof.ml @@ -1,6 +1,6 @@ (* TEST - flags = "-dshape" - * expect + flags = "-dshape"; + expect; *) module Foo : sig diff --git a/testsuite/tests/shapes/open_arg.ml b/testsuite/tests/shapes/open_arg.ml index a422cc8ece..ef98e68cf8 100644 --- a/testsuite/tests/shapes/open_arg.ml +++ b/testsuite/tests/shapes/open_arg.ml @@ -1,6 +1,6 @@ (* TEST - flags = "-dshape" - * expect + flags = "-dshape"; + expect; *) module type Make = functor (I : sig end) -> sig diff --git a/testsuite/tests/shapes/open_struct.ml b/testsuite/tests/shapes/open_struct.ml index cacd030094..fb3199ea9a 100644 --- a/testsuite/tests/shapes/open_struct.ml +++ b/testsuite/tests/shapes/open_struct.ml @@ -1,6 +1,6 @@ (* TEST - flags = "-dshape" - * expect + flags = "-dshape"; + expect; *) (* Everything that couldn't go anywhere else. *) diff --git a/testsuite/tests/shapes/recmodules.ml b/testsuite/tests/shapes/recmodules.ml index c6f743e4b4..f852358436 100644 --- a/testsuite/tests/shapes/recmodules.ml +++ b/testsuite/tests/shapes/recmodules.ml @@ -1,6 +1,6 @@ (* TEST - flags = "-dshape" - * expect + flags = "-dshape"; + expect; *) (**********) diff --git a/testsuite/tests/shapes/rotor_example.ml b/testsuite/tests/shapes/rotor_example.ml index 5802595844..924d63b553 100644 --- a/testsuite/tests/shapes/rotor_example.ml +++ b/testsuite/tests/shapes/rotor_example.ml @@ -1,6 +1,6 @@ (* TEST - flags = "-dshape" - * expect + flags = "-dshape"; + expect; *) (* We depart slightly from the example in the PLDI'19 paper, which actually diff --git a/testsuite/tests/shapes/simple.ml b/testsuite/tests/shapes/simple.ml index 7e833ce8b8..421a66b7b8 100644 --- a/testsuite/tests/shapes/simple.ml +++ b/testsuite/tests/shapes/simple.ml @@ -1,6 +1,6 @@ (* TEST - flags = "-dshape" - * expect + flags = "-dshape"; + expect; *) let x = () diff --git a/testsuite/tests/shapes/typeof_include.ml b/testsuite/tests/shapes/typeof_include.ml index 5dd60fab6e..724e60281e 100644 --- a/testsuite/tests/shapes/typeof_include.ml +++ b/testsuite/tests/shapes/typeof_include.ml @@ -1,6 +1,6 @@ (* TEST - flags = "-dshape" - * expect + flags = "-dshape"; + expect; *) module type S = sig diff --git a/testsuite/tests/statmemprof/alloc_counts.ml b/testsuite/tests/statmemprof/alloc_counts.ml index de0d1e9e49..ce8a90fc04 100644 --- a/testsuite/tests/statmemprof/alloc_counts.ml +++ b/testsuite/tests/statmemprof/alloc_counts.ml @@ -1,6 +1,6 @@ (* TEST -* skip -reason = "port stat-mem-prof : https://github.com/ocaml/ocaml/pull/8634" + reason = "port stat-mem-prof : https://github.com/ocaml/ocaml/pull/8634"; + skip; *) module MP = Gc.Memprof diff --git a/testsuite/tests/statmemprof/arrays_in_major.ml b/testsuite/tests/statmemprof/arrays_in_major.ml index eb627324ba..1dd253dcd6 100644 --- a/testsuite/tests/statmemprof/arrays_in_major.ml +++ b/testsuite/tests/statmemprof/arrays_in_major.ml @@ -1,7 +1,7 @@ (* TEST - flags = "-g" - * skip - reason = "port stat-mem-prof : https://github.com/ocaml/ocaml/pull/8634" + flags = "-g"; + reason = "port stat-mem-prof : https://github.com/ocaml/ocaml/pull/8634"; + skip; *) open Gc.Memprof diff --git a/testsuite/tests/statmemprof/arrays_in_minor.ml b/testsuite/tests/statmemprof/arrays_in_minor.ml index 4359642d0e..2ef7854902 100644 --- a/testsuite/tests/statmemprof/arrays_in_minor.ml +++ b/testsuite/tests/statmemprof/arrays_in_minor.ml @@ -1,7 +1,7 @@ (* TEST - flags = "-g" - * skip - reason = "port stat-mem-prof : https://github.com/ocaml/ocaml/pull/8634" + flags = "-g"; + reason = "port stat-mem-prof : https://github.com/ocaml/ocaml/pull/8634"; + skip; *) open Gc.Memprof diff --git a/testsuite/tests/statmemprof/blocking_in_callback.ml b/testsuite/tests/statmemprof/blocking_in_callback.ml index e1e40f1fb6..72d59e4f32 100644 --- a/testsuite/tests/statmemprof/blocking_in_callback.ml +++ b/testsuite/tests/statmemprof/blocking_in_callback.ml @@ -1,10 +1,16 @@ (* TEST -* hassysthreads -include systhreads -* skip -reason = "port stat-mem-prof : https://github.com/ocaml/ocaml/pull/8634" -** bytecode -** native + { + include systhreads; + hassysthreads; + }{ + reason = "port stat-mem-prof : https://github.com/ocaml/ocaml/pull/8634"; + skip; + { + bytecode; + }{ + native; + } + } *) let cnt = ref 0 diff --git a/testsuite/tests/statmemprof/callstacks.ml b/testsuite/tests/statmemprof/callstacks.ml index e864a50019..41263578f4 100644 --- a/testsuite/tests/statmemprof/callstacks.ml +++ b/testsuite/tests/statmemprof/callstacks.ml @@ -1,19 +1,28 @@ (* TEST - flags = "-g -w -5" - - * flat-float-array - reference = "${test_source_directory}/callstacks.flat-float-array.reference" - * skip - reason = "port stat-mem-prof : https://github.com/ocaml/ocaml/pull/8634" - ** native - ** bytecode - - * no-flat-float-array - reference = "${test_source_directory}/callstacks.no-flat-float-array.reference" - * skip - reason = "port stat-mem-prof : https://github.com/ocaml/ocaml/pull/8634" - ** native - ** bytecode + flags = "-g -w -5"; + { + reference = "${test_source_directory}/callstacks.flat-float-array.reference"; + flat-float-array; + }{ + reason = "port stat-mem-prof : https://github.com/ocaml/ocaml/pull/8634"; + skip; + { + native; + }{ + bytecode; + } + }{ + reference = "${test_source_directory}/callstacks.no-flat-float-array.reference"; + no-flat-float-array; + }{ + reason = "port stat-mem-prof : https://github.com/ocaml/ocaml/pull/8634"; + skip; + { + native; + }{ + bytecode; + } + } *) open Gc.Memprof diff --git a/testsuite/tests/statmemprof/comballoc.ml b/testsuite/tests/statmemprof/comballoc.ml index 60ca4a0123..ae35807ba5 100644 --- a/testsuite/tests/statmemprof/comballoc.ml +++ b/testsuite/tests/statmemprof/comballoc.ml @@ -1,11 +1,14 @@ (* TEST - flags = "-g" - * skip - reason = "port stat-mem-prof : https://github.com/ocaml/ocaml/pull/8634" - ** bytecode - reference = "${test_source_directory}/comballoc.byte.reference" - ** native - reference = "${test_source_directory}/comballoc.opt.reference" + flags = "-g"; + reason = "port stat-mem-prof : https://github.com/ocaml/ocaml/pull/8634"; + skip; + { + reference = "${test_source_directory}/comballoc.byte.reference"; + bytecode; + }{ + reference = "${test_source_directory}/comballoc.opt.reference"; + native; + } *) open Gc.Memprof diff --git a/testsuite/tests/statmemprof/custom.ml b/testsuite/tests/statmemprof/custom.ml index 41cf902ec8..71e96d36d7 100644 --- a/testsuite/tests/statmemprof/custom.ml +++ b/testsuite/tests/statmemprof/custom.ml @@ -1,6 +1,6 @@ (* TEST -* skip -reason = "port stat-mem-prof : https://github.com/ocaml/ocaml/pull/8634" + reason = "port stat-mem-prof : https://github.com/ocaml/ocaml/pull/8634"; + skip; *) open Gc.Memprof diff --git a/testsuite/tests/statmemprof/exception_callback.ml b/testsuite/tests/statmemprof/exception_callback.ml index f9f02f690f..fb0cedf87b 100644 --- a/testsuite/tests/statmemprof/exception_callback.ml +++ b/testsuite/tests/statmemprof/exception_callback.ml @@ -1,7 +1,7 @@ (* TEST - exit_status = "2" - * skip - reason = "port stat-mem-prof : https://github.com/ocaml/ocaml/pull/8634" + exit_status = "2"; + reason = "port stat-mem-prof : https://github.com/ocaml/ocaml/pull/8634"; + skip; *) open Gc.Memprof diff --git a/testsuite/tests/statmemprof/exception_callback_minor.ml b/testsuite/tests/statmemprof/exception_callback_minor.ml index 0bb37782be..d389bc5ceb 100644 --- a/testsuite/tests/statmemprof/exception_callback_minor.ml +++ b/testsuite/tests/statmemprof/exception_callback_minor.ml @@ -1,7 +1,7 @@ (* TEST - exit_status = "2" - * skip - reason = "port stat-mem-prof : https://github.com/ocaml/ocaml/pull/8634" + exit_status = "2"; + reason = "port stat-mem-prof : https://github.com/ocaml/ocaml/pull/8634"; + skip; *) open Gc.Memprof diff --git a/testsuite/tests/statmemprof/intern.ml b/testsuite/tests/statmemprof/intern.ml index bebcc3c8ff..f350826137 100644 --- a/testsuite/tests/statmemprof/intern.ml +++ b/testsuite/tests/statmemprof/intern.ml @@ -1,7 +1,7 @@ (* TEST - flags = "-g" - * skip - reason = "port stat-mem-prof : https://github.com/ocaml/ocaml/pull/8634" + flags = "-g"; + reason = "port stat-mem-prof : https://github.com/ocaml/ocaml/pull/8634"; + skip; *) open Gc.Memprof diff --git a/testsuite/tests/statmemprof/lists_in_minor.ml b/testsuite/tests/statmemprof/lists_in_minor.ml index d08716c71b..24ad6316f9 100644 --- a/testsuite/tests/statmemprof/lists_in_minor.ml +++ b/testsuite/tests/statmemprof/lists_in_minor.ml @@ -1,7 +1,7 @@ (* TEST - flags = "-g" - * skip - reason = "port stat-mem-prof : https://github.com/ocaml/ocaml/pull/8634" + flags = "-g"; + reason = "port stat-mem-prof : https://github.com/ocaml/ocaml/pull/8634"; + skip; *) open Gc.Memprof diff --git a/testsuite/tests/statmemprof/minor_no_postpone.ml b/testsuite/tests/statmemprof/minor_no_postpone.ml index 21c8bfb244..395070a2c8 100644 --- a/testsuite/tests/statmemprof/minor_no_postpone.ml +++ b/testsuite/tests/statmemprof/minor_no_postpone.ml @@ -1,7 +1,7 @@ (* TEST - modules = "minor_no_postpone_stub.c" - * skip - reason = "port stat-mem-prof : https://github.com/ocaml/ocaml/pull/8634" + modules = "minor_no_postpone_stub.c"; + reason = "port stat-mem-prof : https://github.com/ocaml/ocaml/pull/8634"; + skip; *) open Gc.Memprof diff --git a/testsuite/tests/statmemprof/moved_while_blocking.ml b/testsuite/tests/statmemprof/moved_while_blocking.ml index bb8dfc9848..197c84b153 100644 --- a/testsuite/tests/statmemprof/moved_while_blocking.ml +++ b/testsuite/tests/statmemprof/moved_while_blocking.ml @@ -1,10 +1,16 @@ (* TEST -* hassysthreads -include systhreads -* skip -reason = "port stat-mem-prof : https://github.com/ocaml/ocaml/pull/8634" -** bytecode -** native + { + include systhreads; + hassysthreads; + }{ + reason = "port stat-mem-prof : https://github.com/ocaml/ocaml/pull/8634"; + skip; + { + bytecode; + }{ + native; + } + } *) let t2_begin = Atomic.make false diff --git a/testsuite/tests/statmemprof/thread_exit_in_callback.ml b/testsuite/tests/statmemprof/thread_exit_in_callback.ml index 28e2aabb8b..66d7c60183 100644 --- a/testsuite/tests/statmemprof/thread_exit_in_callback.ml +++ b/testsuite/tests/statmemprof/thread_exit_in_callback.ml @@ -1,10 +1,16 @@ (* TEST -* hassysthreads -include systhreads -* skip -reason = "port stat-mem-prof : https://github.com/ocaml/ocaml/pull/8634" -** bytecode -** native + { + include systhreads; + hassysthreads; + }{ + reason = "port stat-mem-prof : https://github.com/ocaml/ocaml/pull/8634"; + skip; + { + bytecode; + }{ + native; + } + } *) let _ = diff --git a/testsuite/tests/tmc/ambiguities.ml b/testsuite/tests/tmc/ambiguities.ml index 55d99fe236..0f846587cd 100644 --- a/testsuite/tests/tmc/ambiguities.ml +++ b/testsuite/tests/tmc/ambiguities.ml @@ -1,5 +1,6 @@ (* TEST - * expect *) + expect; +*) type 'a tree = | Leaf of 'a | Node of 'a tree * 'a tree diff --git a/testsuite/tests/tmc/other_features.ml b/testsuite/tests/tmc/other_features.ml index 0183b01858..d75e1dab0c 100644 --- a/testsuite/tests/tmc/other_features.ml +++ b/testsuite/tests/tmc/other_features.ml @@ -1,5 +1,6 @@ (* TEST - * expect *) + expect; +*) module Non_recursive_let_bad = struct type 'a t = diff --git a/testsuite/tests/tmc/partial_application.ml b/testsuite/tests/tmc/partial_application.ml index 7721416f82..35ddd35e8b 100644 --- a/testsuite/tests/tmc/partial_application.ml +++ b/testsuite/tests/tmc/partial_application.ml @@ -1,6 +1,6 @@ -(* TEST - * bytecode - * native +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + *) type t = Ret of (unit -> unit) | Next of t @@ -17,3 +17,11 @@ let () = match g ~first:true with | Next (Ret f) -> f () | _ -> assert false + +(* TEST + { + bytecode; + }{ + native; + } +*) diff --git a/testsuite/tests/tmc/readable_output.ml b/testsuite/tests/tmc/readable_output.ml index 1e931d7720..0cf0140a02 100644 --- a/testsuite/tests/tmc/readable_output.ml +++ b/testsuite/tests/tmc/readable_output.ml @@ -1,6 +1,7 @@ (* TEST - flags = "-dlambda -dno-unique-ids" - * expect *) + flags = "-dlambda -dno-unique-ids"; + expect; +*) (* Check that the code produced by TMC reads reasonably well. *) let[@tail_mod_cons] rec map f = function diff --git a/testsuite/tests/tmc/semantic.ml b/testsuite/tests/tmc/semantic.ml index 32ffed168a..3e99e5a947 100644 --- a/testsuite/tests/tmc/semantic.ml +++ b/testsuite/tests/tmc/semantic.ml @@ -1,5 +1,5 @@ (* TEST - * bytecode + bytecode; *) (* Test that evaluation order of constructor arguments is preserved. diff --git a/testsuite/tests/tmc/stack_space.ml b/testsuite/tests/tmc/stack_space.ml index 664cc2e668..45499db65a 100644 --- a/testsuite/tests/tmc/stack_space.ml +++ b/testsuite/tests/tmc/stack_space.ml @@ -1,13 +1,13 @@ (* TEST - * setup-ocamlc.byte-build-env - ** ocamlc.byte - module = "stack_space.ml" - *** ocamlc.byte - program = "./test.byte.exe" - all_modules = "stack_space.cmo" - module = "" - **** run - ocamlrunparam += ",l=300" + setup-ocamlc.byte-build-env; + module = "stack_space.ml"; + ocamlc.byte; + program = "./test.byte.exe"; + all_modules = "stack_space.cmo"; + module = ""; + ocamlc.byte; + ocamlrunparam += ",l=300"; + run; *) (* large with respect to the stack-size=300 setting above *) diff --git a/testsuite/tests/tmc/tupled_function.ml b/testsuite/tests/tmc/tupled_function.ml index 605bab9886..5ed4172f9a 100644 --- a/testsuite/tests/tmc/tupled_function.ml +++ b/testsuite/tests/tmc/tupled_function.ml @@ -1,6 +1,9 @@ (* TEST - * bytecode - * native + { + bytecode; + }{ + native; + } *) type 'a t = | N of 'a diff --git a/testsuite/tests/tmc/tupled_function_calls.ml b/testsuite/tests/tmc/tupled_function_calls.ml index 1ce7fa5f6e..a99354def4 100644 --- a/testsuite/tests/tmc/tupled_function_calls.ml +++ b/testsuite/tests/tmc/tupled_function_calls.ml @@ -1,6 +1,6 @@ -(* TEST - * bytecode - * native +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + *) (* this works as expected *) @@ -19,3 +19,11 @@ let[@tail_mod_cons] rec tupled_map_not_direct (f, li) = | x :: xs -> let pair = (f, xs) in f x :: (tupled_map_not_direct[@tailcall true]) pair + +(* TEST + { + bytecode; + }{ + native; + } +*) diff --git a/testsuite/tests/tmc/usage_warnings.ml b/testsuite/tests/tmc/usage_warnings.ml index 966b65983f..009210a613 100644 --- a/testsuite/tests/tmc/usage_warnings.ml +++ b/testsuite/tests/tmc/usage_warnings.ml @@ -1,5 +1,6 @@ (* TEST - * expect *) + expect; +*) (* build-up *) let[@tail_mod_cons] rec append xs ys = diff --git a/testsuite/tests/tool-caml-tex/ellipses.ml b/testsuite/tests/tool-caml-tex/ellipses.ml index 75f717c88a..bc0105c209 100644 --- a/testsuite/tests/tool-caml-tex/ellipses.ml +++ b/testsuite/tests/tool-caml-tex/ellipses.ml @@ -1,13 +1,12 @@ (* TEST - reference="${test_source_directory}/ellipses.reference" - output="ellipses.output" - readonly_files = "${test_source_directory}/ellipses.input" - script = "${ocamlrun} ${ocamlsrcdir}/tools/ocamltex \ - -repo-root ${ocamlsrcdir} ${readonly_files} -o ${output}" - * hasstr - ** hasunix - *** native-compiler - **** shared-libraries - ***** script with unix,str - ****** check-program-output + reference = "${test_source_directory}/ellipses.reference"; + output = "ellipses.output"; + readonly_files = "${test_source_directory}/ellipses.input"; + script = "${ocamlrun} ${ocamlsrcdir}/tools/ocamltex -repo-root ${ocamlsrcdir} ${readonly_files} -o ${output}"; + hasstr; + hasunix; + native-compiler; + shared-libraries; + script with unix, str; + check-program-output; *) diff --git a/testsuite/tests/tool-caml-tex/redirections.ml b/testsuite/tests/tool-caml-tex/redirections.ml index f78875c937..072f11d9f5 100644 --- a/testsuite/tests/tool-caml-tex/redirections.ml +++ b/testsuite/tests/tool-caml-tex/redirections.ml @@ -1,18 +1,19 @@ (* TEST - reference="${test_source_directory}/redirections.reference" - output="redirections.output" - readonly_files = "${test_source_directory}/redirections.input" - script = "${ocamlrun} ${ocamlsrcdir}/tools/ocamltex \ - -repo-root ${ocamlsrcdir} ${readonly_files} -o ${output}" - * hasstr - ** hasunix - *** native-compiler - **** shared-libraries - ***** script with unix,str - ****** check-program-output - **** no-shared-libraries - ***** script with unix,str - script = "${ocamlsrcdir}/tools/ocamltex \ - -repo-root ${ocamlsrcdir} ${readonly_files} -o ${output}" - ****** check-program-output + reference = "${test_source_directory}/redirections.reference"; + output = "redirections.output"; + readonly_files = "${test_source_directory}/redirections.input"; + script = "${ocamlrun} ${ocamlsrcdir}/tools/ocamltex -repo-root ${ocamlsrcdir} ${readonly_files} -o ${output}"; + hasstr; + hasunix; + native-compiler; + { + shared-libraries; + script with unix, str; + check-program-output; + }{ + no-shared-libraries; + script = "${ocamlsrcdir}/tools/ocamltex -repo-root ${ocamlsrcdir} ${readonly_files} -o ${output}"; + script with unix, str; + check-program-output; + } *) diff --git a/testsuite/tests/tool-command-line/test-o-one-c-file.ml b/testsuite/tests/tool-command-line/test-o-one-c-file.ml index 0d35166787..04e949255b 100644 --- a/testsuite/tests/tool-command-line/test-o-one-c-file.ml +++ b/testsuite/tests/tool-command-line/test-o-one-c-file.ml @@ -1,14 +1,14 @@ (* TEST -readonly_files = "hello.c" -* setup-ocamlopt.opt-build-env -** script -script = "mkdir outputdir" -*** ocamlopt.opt -all_modules = "hello.c" -compile_only = "true" -flags = "-o outputdir/hello.${objext}" -**** file-exists -file = "outputdir/hello.${objext}" + readonly_files = "hello.c"; + setup-ocamlopt.opt-build-env; + script = "mkdir outputdir"; + script; + all_modules = "hello.c"; + compile_only = "true"; + flags = "-o outputdir/hello.${objext}"; + ocamlopt.opt; + file = "outputdir/hello.${objext}"; + file-exists; *) (* diff --git a/testsuite/tests/tool-command-line/test-o-several-files.ml b/testsuite/tests/tool-command-line/test-o-several-files.ml index 090ace5043..8c5f95eedf 100644 --- a/testsuite/tests/tool-command-line/test-o-several-files.ml +++ b/testsuite/tests/tool-command-line/test-o-several-files.ml @@ -1,11 +1,11 @@ (* TEST -* setup-ocamlopt.opt-build-env -** ocamlopt.opt -all_modules = "foo.c bar.c" -compile_only = "true" -flags = "-o outputdir/baz.${objext}" -ocamlopt_opt_exit_status = "2" -*** check-ocamlopt.opt-output + setup-ocamlopt.opt-build-env; + all_modules = "foo.c bar.c"; + compile_only = "true"; + flags = "-o outputdir/baz.${objext}"; + ocamlopt_opt_exit_status = "2"; + ocamlopt.opt; + check-ocamlopt.opt-output; *) (* diff --git a/testsuite/tests/tool-command-line/test-unknown-file.ml b/testsuite/tests/tool-command-line/test-unknown-file.ml index 148220e5ce..2d09383701 100644 --- a/testsuite/tests/tool-command-line/test-unknown-file.ml +++ b/testsuite/tests/tool-command-line/test-unknown-file.ml @@ -1,31 +1,30 @@ (* TEST - -readonly_files = "unknown-file" - -* setup-ocamlc.byte-build-env -compiler_output = "compiler-output.raw" -** ocamlc.byte -all_modules = "" -flags = "unknown-file" -ocamlc_byte_exit_status = "2" -*** script -script = "grep 'know what to do with unknown-file' compiler-output.raw" -output = "compiler-output" -**** check-ocamlc.byte-output -compiler_output = "compiler-output" - -* setup-ocamlopt.byte-build-env -compiler_output = "compiler-output.raw" -** ocamlopt.byte -all_modules = "" -flags = "unknown-file" -ocamlopt_byte_exit_status = "2" -*** script -script = "grep 'know what to do with unknown-file' compiler-output.raw" -output = "compiler-output" -**** check-ocamlopt.byte-output -compiler_output = "compiler-output" - + readonly_files = "unknown-file"; + { + compiler_output = "compiler-output.raw"; + setup-ocamlc.byte-build-env; + all_modules = ""; + flags = "unknown-file"; + ocamlc_byte_exit_status = "2"; + ocamlc.byte; + script = "grep 'know what to do with unknown-file' compiler-output.raw"; + output = "compiler-output"; + script; + compiler_output = "compiler-output"; + check-ocamlc.byte-output; + }{ + compiler_output = "compiler-output.raw"; + setup-ocamlopt.byte-build-env; + all_modules = ""; + flags = "unknown-file"; + ocamlopt_byte_exit_status = "2"; + ocamlopt.byte; + script = "grep 'know what to do with unknown-file' compiler-output.raw"; + output = "compiler-output"; + script; + compiler_output = "compiler-output"; + check-ocamlopt.byte-output; + } *) (* diff --git a/testsuite/tests/tool-debugger/basic/debuggee.ml b/testsuite/tests/tool-debugger/basic/debuggee.ml index 91ad3c21dc..a5320cf591 100644 --- a/testsuite/tests/tool-debugger/basic/debuggee.ml +++ b/testsuite/tests/tool-debugger/basic/debuggee.ml @@ -1,14 +1,14 @@ (* TEST -set foo = "bar" -flags += " -g " -ocamldebug_script = "${test_source_directory}/input_script" -* debugger -** shared-libraries -*** setup-ocamlc.byte-build-env -**** ocamlc.byte -***** check-ocamlc.byte-output -****** ocamldebug -******* check-program-output + set foo = "bar"; + flags += " -g "; + ocamldebug_script = "${test_source_directory}/input_script"; + debugger; + shared-libraries; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; + ocamldebug; + check-program-output; *) print_endline Sys.argv.(1);; diff --git a/testsuite/tests/tool-debugger/dynlink/host.ml b/testsuite/tests/tool-debugger/dynlink/host.ml index f46ef8a022..ef12572f68 100644 --- a/testsuite/tests/tool-debugger/dynlink/host.ml +++ b/testsuite/tests/tool-debugger/dynlink/host.ml @@ -1,35 +1,32 @@ (* TEST - -include dynlink -readonly_files = "host.ml plugin.ml" -libraries = "" - -flags += " -g " -ocamldebug_script = "${test_source_directory}/input_script" - -* debugger -** shared-libraries -*** setup-ocamlc.byte-build-env -**** ocamlc.byte -module = "host.ml" -***** ocamlc.byte -module = "plugin.ml" -****** ocamlc.byte -module = "" -all_modules = "host.cmo" -program = "${test_build_directory}/host.byte" -libraries = "dynlink" - -******* run -output = "host.output" -******** check-program-output -reference = "${test_source_directory}/host.reference" - -******** ocamldebug -output = "host.debug.output" -********* check-program-output -reference = "${test_source_directory}/host.debug.reference" - + include dynlink; + readonly_files = "host.ml plugin.ml"; + libraries = ""; + flags += " -g "; + ocamldebug_script = "${test_source_directory}/input_script"; + debugger; + shared-libraries; + setup-ocamlc.byte-build-env; + module = "host.ml"; + ocamlc.byte; + module = "plugin.ml"; + ocamlc.byte; + module = ""; + all_modules = "host.cmo"; + program = "${test_build_directory}/host.byte"; + libraries = "dynlink"; + ocamlc.byte; + output = "host.output"; + run; + { + reference = "${test_source_directory}/host.reference"; + check-program-output; + }{ + output = "host.debug.output"; + ocamldebug; + reference = "${test_source_directory}/host.debug.reference"; + check-program-output; + } *) let () = print_endline "hello host"; Dynlink.loadfile "plugin.cmo" diff --git a/testsuite/tests/tool-debugger/find-artifacts/debuggee.ml b/testsuite/tests/tool-debugger/find-artifacts/debuggee.ml index 70aee3ff04..37544574d9 100644 --- a/testsuite/tests/tool-debugger/find-artifacts/debuggee.ml +++ b/testsuite/tests/tool-debugger/find-artifacts/debuggee.ml @@ -1,25 +1,25 @@ (* TEST -ocamldebug_script = "${test_source_directory}/input_script" -* debugger -** shared-libraries -*** setup-ocamlc.byte-build-env -**** script -script = "mkdir out" -***** ocamlc.byte -flags = "-g -c" -all_modules = "${test_source_directory}/in/blah.ml" -program = "out/blah.cmo" -****** ocamlc.byte -program = "out/foo.cmo" -flags = "-I out -g -c" -all_modules = "${test_source_directory}/in/foo.ml" -******* ocamlc.byte -all_modules = "out/blah.cmo out/foo.cmo" -flags = " -g " -program = "debuggee.exe" -******** check-ocamlc.byte-output -********* ocamldebug -********** check-program-output + ocamldebug_script = "${test_source_directory}/input_script"; + debugger; + shared-libraries; + setup-ocamlc.byte-build-env; + script = "mkdir out"; + script; + flags = "-g -c"; + all_modules = "${test_source_directory}/in/blah.ml"; + program = "out/blah.cmo"; + ocamlc.byte; + program = "out/foo.cmo"; + flags = "-I out -g -c"; + all_modules = "${test_source_directory}/in/foo.ml"; + ocamlc.byte; + all_modules = "out/blah.cmo out/foo.cmo"; + flags = " -g "; + program = "debuggee.exe"; + ocamlc.byte; + check-ocamlc.byte-output; + ocamldebug; + check-program-output; *) (* This file only contains the specification of how to run the test *) diff --git a/testsuite/tests/tool-debugger/module_named_main/main.ml b/testsuite/tests/tool-debugger/module_named_main/main.ml index 25eebe7c02..8c374be083 100644 --- a/testsuite/tests/tool-debugger/module_named_main/main.ml +++ b/testsuite/tests/tool-debugger/module_named_main/main.ml @@ -1,13 +1,13 @@ -(* TEST -flags += " -g " -ocamldebug_script = "${test_source_directory}/input_script" -* debugger -** shared-libraries -*** setup-ocamlc.byte-build-env -**** ocamlc.byte -***** check-ocamlc.byte-output -****** ocamldebug -******* check-program-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + + + + + *) module Submodule = struct @@ -28,3 +28,15 @@ let debug () = ;; debug (); + +(* TEST + flags += " -g "; + ocamldebug_script = "${test_source_directory}/input_script"; + debugger; + shared-libraries; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; + ocamldebug; + check-program-output; +*) diff --git a/testsuite/tests/tool-debugger/no_debug_event/noev.ml b/testsuite/tests/tool-debugger/no_debug_event/noev.ml index 4eb334ea84..746b310b96 100644 --- a/testsuite/tests/tool-debugger/no_debug_event/noev.ml +++ b/testsuite/tests/tool-debugger/no_debug_event/noev.ml @@ -1,28 +1,28 @@ (* TEST -readonly_files = "a.ml b.ml" -ocamldebug_script = "${test_source_directory}/input_script" -* debugger -** shared-libraries -*** setup-ocamlc.byte-build-env -**** ocamlc.byte -module = "a.ml" -flags = "-g -for-pack foo" -***** ocamlc.byte -module = "" -all_modules = "a.cmo" -program = "foo.cmo" -flags = "-g -pack" -****** ocamlc.byte -module = "b.ml" -flags = " -g " -******* ocamlc.byte -module = "" -flags = " -g " -all_modules = "foo.cmo b.cmo" -program = "${test_build_directory}/noev.exe" -******** check-ocamlc.byte-output -********* ocamldebug -********** check-program-output + readonly_files = "a.ml b.ml"; + ocamldebug_script = "${test_source_directory}/input_script"; + debugger; + shared-libraries; + setup-ocamlc.byte-build-env; + module = "a.ml"; + flags = "-g -for-pack foo"; + ocamlc.byte; + module = ""; + all_modules = "a.cmo"; + program = "foo.cmo"; + flags = "-g -pack"; + ocamlc.byte; + module = "b.ml"; + flags = " -g "; + ocamlc.byte; + module = ""; + flags = " -g "; + all_modules = "foo.cmo b.cmo"; + program = "${test_build_directory}/noev.exe"; + ocamlc.byte; + check-ocamlc.byte-output; + ocamldebug; + check-program-output; *) (* This file only contains the specification of how to run the test *) diff --git a/testsuite/tests/tool-debugger/printer/debuggee.ml b/testsuite/tests/tool-debugger/printer/debuggee.ml index f22a4bd50f..ab5f293a3f 100644 --- a/testsuite/tests/tool-debugger/printer/debuggee.ml +++ b/testsuite/tests/tool-debugger/printer/debuggee.ml @@ -1,17 +1,17 @@ -(* TEST -flags += " -g " -ocamldebug_script = "${test_source_directory}/input_script" -readonly_files = "printer.ml" -include debugger -* debugger -** shared-libraries -*** setup-ocamlc.byte-build-env -**** ocamlc.byte -module = "printer.ml" -**** ocamlc.byte -***** check-ocamlc.byte-output -****** ocamldebug -******* check-program-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + + + + + + + + + *) let f x = @@ -20,3 +20,22 @@ let f x = done let () = f 3 + +(* TEST + flags += " -g "; + ocamldebug_script = "${test_source_directory}/input_script"; + readonly_files = "printer.ml"; + include debugger; + debugger; + shared-libraries; + setup-ocamlc.byte-build-env; + { + module = "printer.ml"; + ocamlc.byte; + }{ + ocamlc.byte; + check-ocamlc.byte-output; + ocamldebug; + check-program-output; + } +*) diff --git a/testsuite/tests/tool-dumpobj/test.ml b/testsuite/tests/tool-dumpobj/test.ml index 240732e361..cf83b7d84a 100644 --- a/testsuite/tests/tool-dumpobj/test.ml +++ b/testsuite/tests/tool-dumpobj/test.ml @@ -1,10 +1,8 @@ (* TEST - -flags = "-nopervasives" - -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** run -**** check-program-output + flags = "-nopervasives"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + run; + check-program-output; *) let x = 42L diff --git a/testsuite/tests/tool-expect-test/clean_typer.ml b/testsuite/tests/tool-expect-test/clean_typer.ml index 535ce8d8f1..0e000ad615 100644 --- a/testsuite/tests/tool-expect-test/clean_typer.ml +++ b/testsuite/tests/tool-expect-test/clean_typer.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module Variants = struct diff --git a/testsuite/tests/tool-lexyacc/calc.ml b/testsuite/tests/tool-lexyacc/calc.ml index ec2bb79572..f0ded38605 100644 --- a/testsuite/tests/tool-lexyacc/calc.ml +++ b/testsuite/tests/tool-lexyacc/calc.ml @@ -1,9 +1,9 @@ (* TEST - modules = "calc_parser.mly calc_lexer.mll" - ocamllex_flags = " -q " - ocamlyacc_flags = " -q " - readonly_files = "calc_input.txt" - stdin = "calc_input.txt" + modules = "calc_parser.mly calc_lexer.mll"; + ocamllex_flags = " -q "; + ocamlyacc_flags = " -q "; + readonly_files = "calc_input.txt"; + stdin = "calc_input.txt"; *) let _ = try diff --git a/testsuite/tests/tool-lexyacc/chars.mll b/testsuite/tests/tool-lexyacc/chars.mll index b91f261859..3bc3ffdf17 100644 --- a/testsuite/tests/tool-lexyacc/chars.mll +++ b/testsuite/tests/tool-lexyacc/chars.mll @@ -1,5 +1,5 @@ (* TEST - ocamllex_flags = " -q " + ocamllex_flags = " -q "; *) { diff --git a/testsuite/tests/tool-lexyacc/csets.mll b/testsuite/tests/tool-lexyacc/csets.mll index 91e9e35fb5..a1aefeee43 100644 --- a/testsuite/tests/tool-lexyacc/csets.mll +++ b/testsuite/tests/tool-lexyacc/csets.mll @@ -1,5 +1,5 @@ (* TEST - ocamllex_flags = " -q " + ocamllex_flags = " -q "; *) let digit = ['0'-'9'] diff --git a/testsuite/tests/tool-lexyacc/mpr7760.mll b/testsuite/tests/tool-lexyacc/mpr7760.mll index bffca2d570..7f3f36dd26 100644 --- a/testsuite/tests/tool-lexyacc/mpr7760.mll +++ b/testsuite/tests/tool-lexyacc/mpr7760.mll @@ -1,5 +1,5 @@ (* TEST - ocamllex_flags = " -q " + ocamllex_flags = " -q "; *) rule read = shortest diff --git a/testsuite/tests/tool-lexyacc/parsecheck.mly b/testsuite/tests/tool-lexyacc/parsecheck.mly index 2acb15f377..57dba9af4e 100644 --- a/testsuite/tests/tool-lexyacc/parsecheck.mly +++ b/testsuite/tests/tool-lexyacc/parsecheck.mly @@ -1,5 +1,5 @@ /* TEST - ocamlyacc_flags = " -q --strict " + ocamlyacc_flags = " -q --strict "; */ %token <unit> SIMPLE %type <unit> silly diff --git a/testsuite/tests/tool-ocaml-annot/failure.ml b/testsuite/tests/tool-ocaml-annot/failure.ml index fd9ad0fbe6..4afef598f6 100644 --- a/testsuite/tests/tool-ocaml-annot/failure.ml +++ b/testsuite/tests/tool-ocaml-annot/failure.ml @@ -1,17 +1,17 @@ (* TEST - -flags = "-annot" -script = "sh ${test_source_directory}/check-annot.sh failure" -ocamlc_byte_exit_status = "2" -ocamlopt_byte_exit_status = "2" - -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** script - -* setup-ocamlopt.byte-build-env -** ocamlopt.byte -*** script + flags = "-annot"; + script = "sh ${test_source_directory}/check-annot.sh failure"; + ocamlc_byte_exit_status = "2"; + ocamlopt_byte_exit_status = "2"; + { + setup-ocamlc.byte-build-env; + ocamlc.byte; + script; + }{ + setup-ocamlopt.byte-build-env; + ocamlopt.byte; + script; + } *) (* Check that .annot files are emitted in case of failed compilation. *) diff --git a/testsuite/tests/tool-ocaml-annot/success.ml b/testsuite/tests/tool-ocaml-annot/success.ml index 126799c980..396861a55b 100644 --- a/testsuite/tests/tool-ocaml-annot/success.ml +++ b/testsuite/tests/tool-ocaml-annot/success.ml @@ -1,15 +1,15 @@ (* TEST - -flags = "-annot" -script = "sh ${test_source_directory}/check-annot.sh success" - -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** script - -* setup-ocamlopt.byte-build-env -** ocamlopt.byte -*** script + flags = "-annot"; + script = "sh ${test_source_directory}/check-annot.sh success"; + { + setup-ocamlc.byte-build-env; + ocamlc.byte; + script; + }{ + setup-ocamlopt.byte-build-env; + ocamlopt.byte; + script; + } *) (* Check that .annot files are emitted in case of regular successful diff --git a/testsuite/tests/tool-ocaml-annot/typeonly.ml b/testsuite/tests/tool-ocaml-annot/typeonly.ml index db8d1eae25..75ccf668e5 100644 --- a/testsuite/tests/tool-ocaml-annot/typeonly.ml +++ b/testsuite/tests/tool-ocaml-annot/typeonly.ml @@ -1,16 +1,16 @@ (* TEST - -flags = "-i -annot" -compile_only = "true" -script = "sh ${test_source_directory}/check-annot.sh typeonly" - -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** script - -* setup-ocamlopt.byte-build-env -** ocamlopt.byte -*** script + flags = "-i -annot"; + compile_only = "true"; + script = "sh ${test_source_directory}/check-annot.sh typeonly"; + { + setup-ocamlc.byte-build-env; + ocamlc.byte; + script; + }{ + setup-ocamlopt.byte-build-env; + ocamlopt.byte; + script; + } *) (* Check that .annot files are emitted in case of type-only compilation. *) diff --git a/testsuite/tests/tool-ocaml/directive_failure.ml b/testsuite/tests/tool-ocaml/directive_failure.ml index e7aa4c6d2d..3c1260ca09 100644 --- a/testsuite/tests/tool-ocaml/directive_failure.ml +++ b/testsuite/tests/tool-ocaml/directive_failure.ml @@ -1,8 +1,8 @@ (* TEST -ocaml_script_as_argument = "true" -ocaml_exit_status = "125" -* setup-ocaml-build-env -** ocaml + ocaml_script_as_argument = "true"; + ocaml_exit_status = "125"; + setup-ocaml-build-env; + ocaml; *) #use "no";; diff --git a/testsuite/tests/tool-ocaml/t000.ml b/testsuite/tests/tool-ocaml/t000.ml index a8413fb10f..15b068fa6f 100644 --- a/testsuite/tests/tool-ocaml/t000.ml +++ b/testsuite/tests/tool-ocaml/t000.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) (* empty file *) diff --git a/testsuite/tests/tool-ocaml/t010-const0.ml b/testsuite/tests/tool-ocaml/t010-const0.ml index 6216683396..4ee3ca3fa3 100644 --- a/testsuite/tests/tool-ocaml/t010-const0.ml +++ b/testsuite/tests/tool-ocaml/t010-const0.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) 0;; diff --git a/testsuite/tests/tool-ocaml/t010-const1.ml b/testsuite/tests/tool-ocaml/t010-const1.ml index a536453d00..73011193e1 100644 --- a/testsuite/tests/tool-ocaml/t010-const1.ml +++ b/testsuite/tests/tool-ocaml/t010-const1.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) 1;; diff --git a/testsuite/tests/tool-ocaml/t010-const2.ml b/testsuite/tests/tool-ocaml/t010-const2.ml index 7f06a72513..a8200e77e4 100644 --- a/testsuite/tests/tool-ocaml/t010-const2.ml +++ b/testsuite/tests/tool-ocaml/t010-const2.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) 2;; diff --git a/testsuite/tests/tool-ocaml/t010-const3.ml b/testsuite/tests/tool-ocaml/t010-const3.ml index 92ed01b9a8..db7e14ee82 100644 --- a/testsuite/tests/tool-ocaml/t010-const3.ml +++ b/testsuite/tests/tool-ocaml/t010-const3.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) 3;; diff --git a/testsuite/tests/tool-ocaml/t011-constint.ml b/testsuite/tests/tool-ocaml/t011-constint.ml index 26a6f1efe3..9b149f330a 100644 --- a/testsuite/tests/tool-ocaml/t011-constint.ml +++ b/testsuite/tests/tool-ocaml/t011-constint.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) 4;; diff --git a/testsuite/tests/tool-ocaml/t020.ml b/testsuite/tests/tool-ocaml/t020.ml index 3d3c3ff8dc..e7c0dc6649 100644 --- a/testsuite/tests/tool-ocaml/t020.ml +++ b/testsuite/tests/tool-ocaml/t020.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) let _ = () in ();; diff --git a/testsuite/tests/tool-ocaml/t021-pushconst1.ml b/testsuite/tests/tool-ocaml/t021-pushconst1.ml index d315d23dba..a9d028ebb1 100644 --- a/testsuite/tests/tool-ocaml/t021-pushconst1.ml +++ b/testsuite/tests/tool-ocaml/t021-pushconst1.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) let _ = () in 1;; diff --git a/testsuite/tests/tool-ocaml/t021-pushconst2.ml b/testsuite/tests/tool-ocaml/t021-pushconst2.ml index df2d22c30a..48d521cf2b 100644 --- a/testsuite/tests/tool-ocaml/t021-pushconst2.ml +++ b/testsuite/tests/tool-ocaml/t021-pushconst2.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) let _ = () in 2;; diff --git a/testsuite/tests/tool-ocaml/t021-pushconst3.ml b/testsuite/tests/tool-ocaml/t021-pushconst3.ml index c07111e952..fd1a31fb9b 100644 --- a/testsuite/tests/tool-ocaml/t021-pushconst3.ml +++ b/testsuite/tests/tool-ocaml/t021-pushconst3.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) let _ = () in 3;; diff --git a/testsuite/tests/tool-ocaml/t022-pushconstint.ml b/testsuite/tests/tool-ocaml/t022-pushconstint.ml index bdb708d2e9..7fb3c3c715 100644 --- a/testsuite/tests/tool-ocaml/t022-pushconstint.ml +++ b/testsuite/tests/tool-ocaml/t022-pushconstint.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) let _ = () in -1;; diff --git a/testsuite/tests/tool-ocaml/t040-makeblock1.ml b/testsuite/tests/tool-ocaml/t040-makeblock1.ml index 1c52df3085..da56950b28 100644 --- a/testsuite/tests/tool-ocaml/t040-makeblock1.ml +++ b/testsuite/tests/tool-ocaml/t040-makeblock1.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) type t = { diff --git a/testsuite/tests/tool-ocaml/t040-makeblock2.ml b/testsuite/tests/tool-ocaml/t040-makeblock2.ml index e96a8b67cd..e6222e3225 100644 --- a/testsuite/tests/tool-ocaml/t040-makeblock2.ml +++ b/testsuite/tests/tool-ocaml/t040-makeblock2.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) type t = { diff --git a/testsuite/tests/tool-ocaml/t040-makeblock3.ml b/testsuite/tests/tool-ocaml/t040-makeblock3.ml index a2083304ef..c8ff9e44fc 100644 --- a/testsuite/tests/tool-ocaml/t040-makeblock3.ml +++ b/testsuite/tests/tool-ocaml/t040-makeblock3.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) type t = { diff --git a/testsuite/tests/tool-ocaml/t041-makeblock.ml b/testsuite/tests/tool-ocaml/t041-makeblock.ml index 8d70bb630b..57b8d68785 100644 --- a/testsuite/tests/tool-ocaml/t041-makeblock.ml +++ b/testsuite/tests/tool-ocaml/t041-makeblock.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) type t = { diff --git a/testsuite/tests/tool-ocaml/t050-getglobal.ml b/testsuite/tests/tool-ocaml/t050-getglobal.ml index cbd7ee1ad8..c5f636c357 100644 --- a/testsuite/tests/tool-ocaml/t050-getglobal.ml +++ b/testsuite/tests/tool-ocaml/t050-getglobal.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) [1];; diff --git a/testsuite/tests/tool-ocaml/t050-pushgetglobal.ml b/testsuite/tests/tool-ocaml/t050-pushgetglobal.ml index e112327967..c0262a9468 100644 --- a/testsuite/tests/tool-ocaml/t050-pushgetglobal.ml +++ b/testsuite/tests/tool-ocaml/t050-pushgetglobal.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) let _ = () in 0.01;; diff --git a/testsuite/tests/tool-ocaml/t051-getglobalfield.ml b/testsuite/tests/tool-ocaml/t051-getglobalfield.ml index a78a5e8e46..9e16ebdb09 100644 --- a/testsuite/tests/tool-ocaml/t051-getglobalfield.ml +++ b/testsuite/tests/tool-ocaml/t051-getglobalfield.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) Lib.x;; diff --git a/testsuite/tests/tool-ocaml/t051-pushgetglobalfield.ml b/testsuite/tests/tool-ocaml/t051-pushgetglobalfield.ml index 26c1e0d1b7..182eb83f2b 100644 --- a/testsuite/tests/tool-ocaml/t051-pushgetglobalfield.ml +++ b/testsuite/tests/tool-ocaml/t051-pushgetglobalfield.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) let _ = () in Lib.x;; diff --git a/testsuite/tests/tool-ocaml/t060-raise.ml b/testsuite/tests/tool-ocaml/t060-raise.ml index 1bee8b2d20..0a116e8198 100644 --- a/testsuite/tests/tool-ocaml/t060-raise.ml +++ b/testsuite/tests/tool-ocaml/t060-raise.ml @@ -1,10 +1,10 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -ocaml_exit_status = "2" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + ocaml_exit_status = "2"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t070-branch.ml b/testsuite/tests/tool-ocaml/t070-branch.ml index 8a58e20e8c..1d7570aba3 100644 --- a/testsuite/tests/tool-ocaml/t070-branch.ml +++ b/testsuite/tests/tool-ocaml/t070-branch.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t070-branchif.ml b/testsuite/tests/tool-ocaml/t070-branchif.ml index a231f04110..9650d404ef 100644 --- a/testsuite/tests/tool-ocaml/t070-branchif.ml +++ b/testsuite/tests/tool-ocaml/t070-branchif.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t070-branchifnot.ml b/testsuite/tests/tool-ocaml/t070-branchifnot.ml index 578380b1f1..cb1fd166e6 100644 --- a/testsuite/tests/tool-ocaml/t070-branchifnot.ml +++ b/testsuite/tests/tool-ocaml/t070-branchifnot.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t071-boolnot.ml b/testsuite/tests/tool-ocaml/t071-boolnot.ml index 3400655bff..db814ba4a4 100644 --- a/testsuite/tests/tool-ocaml/t071-boolnot.ml +++ b/testsuite/tests/tool-ocaml/t071-boolnot.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t080-eq.ml b/testsuite/tests/tool-ocaml/t080-eq.ml index b8fc6455c3..fb1c1429ed 100644 --- a/testsuite/tests/tool-ocaml/t080-eq.ml +++ b/testsuite/tests/tool-ocaml/t080-eq.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t080-geint.ml b/testsuite/tests/tool-ocaml/t080-geint.ml index d604fed654..9dd65a40fe 100644 --- a/testsuite/tests/tool-ocaml/t080-geint.ml +++ b/testsuite/tests/tool-ocaml/t080-geint.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t080-gtint.ml b/testsuite/tests/tool-ocaml/t080-gtint.ml index df53f75199..be75d3bc20 100644 --- a/testsuite/tests/tool-ocaml/t080-gtint.ml +++ b/testsuite/tests/tool-ocaml/t080-gtint.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t080-leint.ml b/testsuite/tests/tool-ocaml/t080-leint.ml index b78aa3a5db..68295f154a 100644 --- a/testsuite/tests/tool-ocaml/t080-leint.ml +++ b/testsuite/tests/tool-ocaml/t080-leint.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t080-ltint.ml b/testsuite/tests/tool-ocaml/t080-ltint.ml index 9737ad1a33..0135b8000f 100644 --- a/testsuite/tests/tool-ocaml/t080-ltint.ml +++ b/testsuite/tests/tool-ocaml/t080-ltint.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t080-neq.ml b/testsuite/tests/tool-ocaml/t080-neq.ml index b1c33aec21..f3510719b7 100644 --- a/testsuite/tests/tool-ocaml/t080-neq.ml +++ b/testsuite/tests/tool-ocaml/t080-neq.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t090-acc0.ml b/testsuite/tests/tool-ocaml/t090-acc0.ml index 0b398c26ea..1892888dbc 100644 --- a/testsuite/tests/tool-ocaml/t090-acc0.ml +++ b/testsuite/tests/tool-ocaml/t090-acc0.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t090-acc1.ml b/testsuite/tests/tool-ocaml/t090-acc1.ml index 8a4dcd1711..823213a9ef 100644 --- a/testsuite/tests/tool-ocaml/t090-acc1.ml +++ b/testsuite/tests/tool-ocaml/t090-acc1.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t090-acc2.ml b/testsuite/tests/tool-ocaml/t090-acc2.ml index 708da881fe..9bb080af8c 100644 --- a/testsuite/tests/tool-ocaml/t090-acc2.ml +++ b/testsuite/tests/tool-ocaml/t090-acc2.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t090-acc3.ml b/testsuite/tests/tool-ocaml/t090-acc3.ml index 9474236d43..445b24f445 100644 --- a/testsuite/tests/tool-ocaml/t090-acc3.ml +++ b/testsuite/tests/tool-ocaml/t090-acc3.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t090-acc4.ml b/testsuite/tests/tool-ocaml/t090-acc4.ml index 673694d059..e272351663 100644 --- a/testsuite/tests/tool-ocaml/t090-acc4.ml +++ b/testsuite/tests/tool-ocaml/t090-acc4.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t090-acc5.ml b/testsuite/tests/tool-ocaml/t090-acc5.ml index f270f5fc17..0e7bd171c0 100644 --- a/testsuite/tests/tool-ocaml/t090-acc5.ml +++ b/testsuite/tests/tool-ocaml/t090-acc5.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t090-acc6.ml b/testsuite/tests/tool-ocaml/t090-acc6.ml index b1d0e83303..35999f0282 100644 --- a/testsuite/tests/tool-ocaml/t090-acc6.ml +++ b/testsuite/tests/tool-ocaml/t090-acc6.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t090-acc7.ml b/testsuite/tests/tool-ocaml/t090-acc7.ml index 64e61e791b..689e9d3164 100644 --- a/testsuite/tests/tool-ocaml/t090-acc7.ml +++ b/testsuite/tests/tool-ocaml/t090-acc7.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t091-acc.ml b/testsuite/tests/tool-ocaml/t091-acc.ml index be3c73ebca..999dca3a3a 100644 --- a/testsuite/tests/tool-ocaml/t091-acc.ml +++ b/testsuite/tests/tool-ocaml/t091-acc.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t092-pushacc.ml b/testsuite/tests/tool-ocaml/t092-pushacc.ml index 26a414b3b5..26931f8723 100644 --- a/testsuite/tests/tool-ocaml/t092-pushacc.ml +++ b/testsuite/tests/tool-ocaml/t092-pushacc.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t092-pushacc0.ml b/testsuite/tests/tool-ocaml/t092-pushacc0.ml index 7199799b90..7d6bd2e6b6 100644 --- a/testsuite/tests/tool-ocaml/t092-pushacc0.ml +++ b/testsuite/tests/tool-ocaml/t092-pushacc0.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t092-pushacc1.ml b/testsuite/tests/tool-ocaml/t092-pushacc1.ml index d6e34cee03..0a7d450727 100644 --- a/testsuite/tests/tool-ocaml/t092-pushacc1.ml +++ b/testsuite/tests/tool-ocaml/t092-pushacc1.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t092-pushacc2.ml b/testsuite/tests/tool-ocaml/t092-pushacc2.ml index 2f1b641bab..ed2adb2f9a 100644 --- a/testsuite/tests/tool-ocaml/t092-pushacc2.ml +++ b/testsuite/tests/tool-ocaml/t092-pushacc2.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t092-pushacc3.ml b/testsuite/tests/tool-ocaml/t092-pushacc3.ml index c0bc7fcd99..95553e0911 100644 --- a/testsuite/tests/tool-ocaml/t092-pushacc3.ml +++ b/testsuite/tests/tool-ocaml/t092-pushacc3.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t092-pushacc4.ml b/testsuite/tests/tool-ocaml/t092-pushacc4.ml index 07dd054eee..84b7d5aff9 100644 --- a/testsuite/tests/tool-ocaml/t092-pushacc4.ml +++ b/testsuite/tests/tool-ocaml/t092-pushacc4.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t092-pushacc5.ml b/testsuite/tests/tool-ocaml/t092-pushacc5.ml index 57c6213e5f..746d0eeec2 100644 --- a/testsuite/tests/tool-ocaml/t092-pushacc5.ml +++ b/testsuite/tests/tool-ocaml/t092-pushacc5.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t092-pushacc6.ml b/testsuite/tests/tool-ocaml/t092-pushacc6.ml index 01304d6a66..4d14f8c80f 100644 --- a/testsuite/tests/tool-ocaml/t092-pushacc6.ml +++ b/testsuite/tests/tool-ocaml/t092-pushacc6.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t092-pushacc7.ml b/testsuite/tests/tool-ocaml/t092-pushacc7.ml index befef4c2f6..ba648b245c 100644 --- a/testsuite/tests/tool-ocaml/t092-pushacc7.ml +++ b/testsuite/tests/tool-ocaml/t092-pushacc7.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t093-pushacc.ml b/testsuite/tests/tool-ocaml/t093-pushacc.ml index efd8d8d8d9..9d35dd38cc 100644 --- a/testsuite/tests/tool-ocaml/t093-pushacc.ml +++ b/testsuite/tests/tool-ocaml/t093-pushacc.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t100-pushtrap.ml b/testsuite/tests/tool-ocaml/t100-pushtrap.ml index 586e720d01..28abb4caf5 100644 --- a/testsuite/tests/tool-ocaml/t100-pushtrap.ml +++ b/testsuite/tests/tool-ocaml/t100-pushtrap.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t101-poptrap.ml b/testsuite/tests/tool-ocaml/t101-poptrap.ml index 842ec08962..5e00863941 100644 --- a/testsuite/tests/tool-ocaml/t101-poptrap.ml +++ b/testsuite/tests/tool-ocaml/t101-poptrap.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t110-addint.ml b/testsuite/tests/tool-ocaml/t110-addint.ml index cc31dc6166..1d689ff180 100644 --- a/testsuite/tests/tool-ocaml/t110-addint.ml +++ b/testsuite/tests/tool-ocaml/t110-addint.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t110-andint.ml b/testsuite/tests/tool-ocaml/t110-andint.ml index 52497d319c..4999cd1119 100644 --- a/testsuite/tests/tool-ocaml/t110-andint.ml +++ b/testsuite/tests/tool-ocaml/t110-andint.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t110-asrint-1.ml b/testsuite/tests/tool-ocaml/t110-asrint-1.ml index fe700edc29..0933bea1cb 100644 --- a/testsuite/tests/tool-ocaml/t110-asrint-1.ml +++ b/testsuite/tests/tool-ocaml/t110-asrint-1.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t110-asrint-2.ml b/testsuite/tests/tool-ocaml/t110-asrint-2.ml index 9f15bde01f..65dcb1fce6 100644 --- a/testsuite/tests/tool-ocaml/t110-asrint-2.ml +++ b/testsuite/tests/tool-ocaml/t110-asrint-2.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t110-divint-1.ml b/testsuite/tests/tool-ocaml/t110-divint-1.ml index 0e1208abe1..59dceadc49 100644 --- a/testsuite/tests/tool-ocaml/t110-divint-1.ml +++ b/testsuite/tests/tool-ocaml/t110-divint-1.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t110-divint-2.ml b/testsuite/tests/tool-ocaml/t110-divint-2.ml index eabec84efd..39bb0b38aa 100644 --- a/testsuite/tests/tool-ocaml/t110-divint-2.ml +++ b/testsuite/tests/tool-ocaml/t110-divint-2.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t110-divint-3.ml b/testsuite/tests/tool-ocaml/t110-divint-3.ml index d17e1350a0..8dde42dac9 100644 --- a/testsuite/tests/tool-ocaml/t110-divint-3.ml +++ b/testsuite/tests/tool-ocaml/t110-divint-3.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t110-lslint.ml b/testsuite/tests/tool-ocaml/t110-lslint.ml index fc903ef8fe..2b4e56f2b3 100644 --- a/testsuite/tests/tool-ocaml/t110-lslint.ml +++ b/testsuite/tests/tool-ocaml/t110-lslint.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t110-lsrint.ml b/testsuite/tests/tool-ocaml/t110-lsrint.ml index 348a2b6a3e..ec1f0023ca 100644 --- a/testsuite/tests/tool-ocaml/t110-lsrint.ml +++ b/testsuite/tests/tool-ocaml/t110-lsrint.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t110-modint-1.ml b/testsuite/tests/tool-ocaml/t110-modint-1.ml index 0bfb65defa..a5e2553188 100644 --- a/testsuite/tests/tool-ocaml/t110-modint-1.ml +++ b/testsuite/tests/tool-ocaml/t110-modint-1.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t110-modint-2.ml b/testsuite/tests/tool-ocaml/t110-modint-2.ml index e2ea7c29a8..3835861df2 100644 --- a/testsuite/tests/tool-ocaml/t110-modint-2.ml +++ b/testsuite/tests/tool-ocaml/t110-modint-2.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t110-mulint.ml b/testsuite/tests/tool-ocaml/t110-mulint.ml index bae1ffb610..49faaa8857 100644 --- a/testsuite/tests/tool-ocaml/t110-mulint.ml +++ b/testsuite/tests/tool-ocaml/t110-mulint.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t110-negint.ml b/testsuite/tests/tool-ocaml/t110-negint.ml index 770a2ee81f..470466e752 100644 --- a/testsuite/tests/tool-ocaml/t110-negint.ml +++ b/testsuite/tests/tool-ocaml/t110-negint.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t110-offsetint.ml b/testsuite/tests/tool-ocaml/t110-offsetint.ml index 9b74667e4f..08db4246cb 100644 --- a/testsuite/tests/tool-ocaml/t110-offsetint.ml +++ b/testsuite/tests/tool-ocaml/t110-offsetint.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t110-orint.ml b/testsuite/tests/tool-ocaml/t110-orint.ml index 8551be84b6..99c3bd1f4c 100644 --- a/testsuite/tests/tool-ocaml/t110-orint.ml +++ b/testsuite/tests/tool-ocaml/t110-orint.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t110-subint.ml b/testsuite/tests/tool-ocaml/t110-subint.ml index 3993dd329e..dcef962805 100644 --- a/testsuite/tests/tool-ocaml/t110-subint.ml +++ b/testsuite/tests/tool-ocaml/t110-subint.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t110-xorint.ml b/testsuite/tests/tool-ocaml/t110-xorint.ml index 2dd2a9b96c..71aaaff1f8 100644 --- a/testsuite/tests/tool-ocaml/t110-xorint.ml +++ b/testsuite/tests/tool-ocaml/t110-xorint.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t120-getstringchar.ml b/testsuite/tests/tool-ocaml/t120-getstringchar.ml index 271022c355..3e38b57d42 100644 --- a/testsuite/tests/tool-ocaml/t120-getstringchar.ml +++ b/testsuite/tests/tool-ocaml/t120-getstringchar.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t121-setstringchar.ml b/testsuite/tests/tool-ocaml/t121-setstringchar.ml index 6ea9899c13..40f8a92d63 100644 --- a/testsuite/tests/tool-ocaml/t121-setstringchar.ml +++ b/testsuite/tests/tool-ocaml/t121-setstringchar.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t130-getvectitem.ml b/testsuite/tests/tool-ocaml/t130-getvectitem.ml index f8af8f1714..fd04d3e530 100644 --- a/testsuite/tests/tool-ocaml/t130-getvectitem.ml +++ b/testsuite/tests/tool-ocaml/t130-getvectitem.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t130-vectlength.ml b/testsuite/tests/tool-ocaml/t130-vectlength.ml index ea56854426..eae6839121 100644 --- a/testsuite/tests/tool-ocaml/t130-vectlength.ml +++ b/testsuite/tests/tool-ocaml/t130-vectlength.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t131-setvectitem.ml b/testsuite/tests/tool-ocaml/t131-setvectitem.ml index abb238f3c4..8f7065ea97 100644 --- a/testsuite/tests/tool-ocaml/t131-setvectitem.ml +++ b/testsuite/tests/tool-ocaml/t131-setvectitem.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t140-switch-1.ml b/testsuite/tests/tool-ocaml/t140-switch-1.ml index 0928b06875..e932d4eb3c 100644 --- a/testsuite/tests/tool-ocaml/t140-switch-1.ml +++ b/testsuite/tests/tool-ocaml/t140-switch-1.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t140-switch-2.ml b/testsuite/tests/tool-ocaml/t140-switch-2.ml index 3089ffbc0d..a7a81a9fe2 100644 --- a/testsuite/tests/tool-ocaml/t140-switch-2.ml +++ b/testsuite/tests/tool-ocaml/t140-switch-2.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t140-switch-3.ml b/testsuite/tests/tool-ocaml/t140-switch-3.ml index ff15ead8a0..35e98bf7c3 100644 --- a/testsuite/tests/tool-ocaml/t140-switch-3.ml +++ b/testsuite/tests/tool-ocaml/t140-switch-3.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t140-switch-4.ml b/testsuite/tests/tool-ocaml/t140-switch-4.ml index 61b7954dd0..4596100adf 100644 --- a/testsuite/tests/tool-ocaml/t140-switch-4.ml +++ b/testsuite/tests/tool-ocaml/t140-switch-4.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t141-switch-5.ml b/testsuite/tests/tool-ocaml/t141-switch-5.ml index 29d2cd5d91..7379a75a04 100644 --- a/testsuite/tests/tool-ocaml/t141-switch-5.ml +++ b/testsuite/tests/tool-ocaml/t141-switch-5.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t141-switch-6.ml b/testsuite/tests/tool-ocaml/t141-switch-6.ml index 34a87740b3..0f5ec6a45e 100644 --- a/testsuite/tests/tool-ocaml/t141-switch-6.ml +++ b/testsuite/tests/tool-ocaml/t141-switch-6.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t141-switch-7.ml b/testsuite/tests/tool-ocaml/t141-switch-7.ml index 137080e0c0..2d4eb469b0 100644 --- a/testsuite/tests/tool-ocaml/t141-switch-7.ml +++ b/testsuite/tests/tool-ocaml/t141-switch-7.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t142-switch-8.ml b/testsuite/tests/tool-ocaml/t142-switch-8.ml index 5d806419cc..78bec9f0f0 100644 --- a/testsuite/tests/tool-ocaml/t142-switch-8.ml +++ b/testsuite/tests/tool-ocaml/t142-switch-8.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t142-switch-9.ml b/testsuite/tests/tool-ocaml/t142-switch-9.ml index 8de4de43d2..31b3fe05ad 100644 --- a/testsuite/tests/tool-ocaml/t142-switch-9.ml +++ b/testsuite/tests/tool-ocaml/t142-switch-9.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t142-switch-A.ml b/testsuite/tests/tool-ocaml/t142-switch-A.ml index 09bfdedfbf..c356d29626 100644 --- a/testsuite/tests/tool-ocaml/t142-switch-A.ml +++ b/testsuite/tests/tool-ocaml/t142-switch-A.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t150-push-1.ml b/testsuite/tests/tool-ocaml/t150-push-1.ml index d13723b409..b34e13f3cd 100644 --- a/testsuite/tests/tool-ocaml/t150-push-1.ml +++ b/testsuite/tests/tool-ocaml/t150-push-1.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t150-push-2.ml b/testsuite/tests/tool-ocaml/t150-push-2.ml index ce9cc2877b..d2c9bc532e 100644 --- a/testsuite/tests/tool-ocaml/t150-push-2.ml +++ b/testsuite/tests/tool-ocaml/t150-push-2.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t160-closure.ml b/testsuite/tests/tool-ocaml/t160-closure.ml index f26a4c9f79..9ad6c07a5c 100644 --- a/testsuite/tests/tool-ocaml/t160-closure.ml +++ b/testsuite/tests/tool-ocaml/t160-closure.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t161-apply1.ml b/testsuite/tests/tool-ocaml/t161-apply1.ml index beccf312fc..5bb6cddc6d 100644 --- a/testsuite/tests/tool-ocaml/t161-apply1.ml +++ b/testsuite/tests/tool-ocaml/t161-apply1.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t162-return.ml b/testsuite/tests/tool-ocaml/t162-return.ml index 664c54b21c..59c549c807 100644 --- a/testsuite/tests/tool-ocaml/t162-return.ml +++ b/testsuite/tests/tool-ocaml/t162-return.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t163.ml b/testsuite/tests/tool-ocaml/t163.ml index 41380ca26b..ea0c181da6 100644 --- a/testsuite/tests/tool-ocaml/t163.ml +++ b/testsuite/tests/tool-ocaml/t163.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t164-apply2.ml b/testsuite/tests/tool-ocaml/t164-apply2.ml index af928e714d..a5f5e7f98c 100644 --- a/testsuite/tests/tool-ocaml/t164-apply2.ml +++ b/testsuite/tests/tool-ocaml/t164-apply2.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t164-apply3.ml b/testsuite/tests/tool-ocaml/t164-apply3.ml index 2c4f1f6e5e..fdc92df92e 100644 --- a/testsuite/tests/tool-ocaml/t164-apply3.ml +++ b/testsuite/tests/tool-ocaml/t164-apply3.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t165-apply.ml b/testsuite/tests/tool-ocaml/t165-apply.ml index c06caf0f9b..ab51c87d52 100644 --- a/testsuite/tests/tool-ocaml/t165-apply.ml +++ b/testsuite/tests/tool-ocaml/t165-apply.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t170-envacc2.ml b/testsuite/tests/tool-ocaml/t170-envacc2.ml index 3484ca54fd..19c183fb85 100644 --- a/testsuite/tests/tool-ocaml/t170-envacc2.ml +++ b/testsuite/tests/tool-ocaml/t170-envacc2.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t170-envacc3.ml b/testsuite/tests/tool-ocaml/t170-envacc3.ml index 583fd00fdb..9b494a0a05 100644 --- a/testsuite/tests/tool-ocaml/t170-envacc3.ml +++ b/testsuite/tests/tool-ocaml/t170-envacc3.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t170-envacc4.ml b/testsuite/tests/tool-ocaml/t170-envacc4.ml index 70df1ac98f..6a44794f41 100644 --- a/testsuite/tests/tool-ocaml/t170-envacc4.ml +++ b/testsuite/tests/tool-ocaml/t170-envacc4.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t171-envacc.ml b/testsuite/tests/tool-ocaml/t171-envacc.ml index 98bb61f5d1..f91f4c748a 100644 --- a/testsuite/tests/tool-ocaml/t171-envacc.ml +++ b/testsuite/tests/tool-ocaml/t171-envacc.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t172-pushenvacc1.ml b/testsuite/tests/tool-ocaml/t172-pushenvacc1.ml index 7ad3287eb6..55d2600163 100644 --- a/testsuite/tests/tool-ocaml/t172-pushenvacc1.ml +++ b/testsuite/tests/tool-ocaml/t172-pushenvacc1.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t172-pushenvacc2.ml b/testsuite/tests/tool-ocaml/t172-pushenvacc2.ml index 70e2311579..ae034cc1ec 100644 --- a/testsuite/tests/tool-ocaml/t172-pushenvacc2.ml +++ b/testsuite/tests/tool-ocaml/t172-pushenvacc2.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t172-pushenvacc3.ml b/testsuite/tests/tool-ocaml/t172-pushenvacc3.ml index 170dc2afbc..4203cc1c41 100644 --- a/testsuite/tests/tool-ocaml/t172-pushenvacc3.ml +++ b/testsuite/tests/tool-ocaml/t172-pushenvacc3.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t172-pushenvacc4.ml b/testsuite/tests/tool-ocaml/t172-pushenvacc4.ml index 16967b6f6f..061abe3d18 100644 --- a/testsuite/tests/tool-ocaml/t172-pushenvacc4.ml +++ b/testsuite/tests/tool-ocaml/t172-pushenvacc4.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t173-pushenvacc.ml b/testsuite/tests/tool-ocaml/t173-pushenvacc.ml index 3a2c19ddb0..2a43f1c68f 100644 --- a/testsuite/tests/tool-ocaml/t173-pushenvacc.ml +++ b/testsuite/tests/tool-ocaml/t173-pushenvacc.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t180-appterm1.ml b/testsuite/tests/tool-ocaml/t180-appterm1.ml index 42e6c32386..56853e159e 100644 --- a/testsuite/tests/tool-ocaml/t180-appterm1.ml +++ b/testsuite/tests/tool-ocaml/t180-appterm1.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t180-appterm2.ml b/testsuite/tests/tool-ocaml/t180-appterm2.ml index 0afccadf1f..2f68cd13ac 100644 --- a/testsuite/tests/tool-ocaml/t180-appterm2.ml +++ b/testsuite/tests/tool-ocaml/t180-appterm2.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t180-appterm3.ml b/testsuite/tests/tool-ocaml/t180-appterm3.ml index d0ed1e6743..788c0adab8 100644 --- a/testsuite/tests/tool-ocaml/t180-appterm3.ml +++ b/testsuite/tests/tool-ocaml/t180-appterm3.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t181-appterm.ml b/testsuite/tests/tool-ocaml/t181-appterm.ml index 4a7778e532..f001d871b6 100644 --- a/testsuite/tests/tool-ocaml/t181-appterm.ml +++ b/testsuite/tests/tool-ocaml/t181-appterm.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t190-makefloatblock-1.ml b/testsuite/tests/tool-ocaml/t190-makefloatblock-1.ml index 0d3c6d1374..22d52d58ac 100644 --- a/testsuite/tests/tool-ocaml/t190-makefloatblock-1.ml +++ b/testsuite/tests/tool-ocaml/t190-makefloatblock-1.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t190-makefloatblock-2.ml b/testsuite/tests/tool-ocaml/t190-makefloatblock-2.ml index 869b6de9e8..5b3ffd7c80 100644 --- a/testsuite/tests/tool-ocaml/t190-makefloatblock-2.ml +++ b/testsuite/tests/tool-ocaml/t190-makefloatblock-2.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t190-makefloatblock-3.ml b/testsuite/tests/tool-ocaml/t190-makefloatblock-3.ml index a966a2f21c..63d8e6bf31 100644 --- a/testsuite/tests/tool-ocaml/t190-makefloatblock-3.ml +++ b/testsuite/tests/tool-ocaml/t190-makefloatblock-3.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t191-vectlength.ml b/testsuite/tests/tool-ocaml/t191-vectlength.ml index ef7a93f5c2..b154108352 100644 --- a/testsuite/tests/tool-ocaml/t191-vectlength.ml +++ b/testsuite/tests/tool-ocaml/t191-vectlength.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t192-getfloatfield-1.ml b/testsuite/tests/tool-ocaml/t192-getfloatfield-1.ml index 74e1f7a6ae..bd4af309e8 100644 --- a/testsuite/tests/tool-ocaml/t192-getfloatfield-1.ml +++ b/testsuite/tests/tool-ocaml/t192-getfloatfield-1.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t192-getfloatfield-2.ml b/testsuite/tests/tool-ocaml/t192-getfloatfield-2.ml index fc224244de..c5b59ebad4 100644 --- a/testsuite/tests/tool-ocaml/t192-getfloatfield-2.ml +++ b/testsuite/tests/tool-ocaml/t192-getfloatfield-2.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t193-setfloatfield-1.ml b/testsuite/tests/tool-ocaml/t193-setfloatfield-1.ml index 708c3bc42c..12e7554882 100644 --- a/testsuite/tests/tool-ocaml/t193-setfloatfield-1.ml +++ b/testsuite/tests/tool-ocaml/t193-setfloatfield-1.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t193-setfloatfield-2.ml b/testsuite/tests/tool-ocaml/t193-setfloatfield-2.ml index 80d010f6ee..d5cc07194a 100644 --- a/testsuite/tests/tool-ocaml/t193-setfloatfield-2.ml +++ b/testsuite/tests/tool-ocaml/t193-setfloatfield-2.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t200-getfield0.ml b/testsuite/tests/tool-ocaml/t200-getfield0.ml index fa768984b7..4be33c0f4a 100644 --- a/testsuite/tests/tool-ocaml/t200-getfield0.ml +++ b/testsuite/tests/tool-ocaml/t200-getfield0.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t200-getfield1.ml b/testsuite/tests/tool-ocaml/t200-getfield1.ml index c394ab2c2f..de07981dc3 100644 --- a/testsuite/tests/tool-ocaml/t200-getfield1.ml +++ b/testsuite/tests/tool-ocaml/t200-getfield1.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t200-getfield2.ml b/testsuite/tests/tool-ocaml/t200-getfield2.ml index 954f86f0d5..d8930fc75c 100644 --- a/testsuite/tests/tool-ocaml/t200-getfield2.ml +++ b/testsuite/tests/tool-ocaml/t200-getfield2.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t200-getfield3.ml b/testsuite/tests/tool-ocaml/t200-getfield3.ml index 3381468e0d..8b2189ca05 100644 --- a/testsuite/tests/tool-ocaml/t200-getfield3.ml +++ b/testsuite/tests/tool-ocaml/t200-getfield3.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t201-getfield.ml b/testsuite/tests/tool-ocaml/t201-getfield.ml index f76fe0057c..253262f201 100644 --- a/testsuite/tests/tool-ocaml/t201-getfield.ml +++ b/testsuite/tests/tool-ocaml/t201-getfield.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t210-setfield0.ml b/testsuite/tests/tool-ocaml/t210-setfield0.ml index 40803c4f20..e1891fa82c 100644 --- a/testsuite/tests/tool-ocaml/t210-setfield0.ml +++ b/testsuite/tests/tool-ocaml/t210-setfield0.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t210-setfield1.ml b/testsuite/tests/tool-ocaml/t210-setfield1.ml index ff65da7a2b..ffbdc0f202 100644 --- a/testsuite/tests/tool-ocaml/t210-setfield1.ml +++ b/testsuite/tests/tool-ocaml/t210-setfield1.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t210-setfield2.ml b/testsuite/tests/tool-ocaml/t210-setfield2.ml index 7a46e87aa6..b7d8cd50b4 100644 --- a/testsuite/tests/tool-ocaml/t210-setfield2.ml +++ b/testsuite/tests/tool-ocaml/t210-setfield2.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t210-setfield3.ml b/testsuite/tests/tool-ocaml/t210-setfield3.ml index 20394fbbdb..d921a3043f 100644 --- a/testsuite/tests/tool-ocaml/t210-setfield3.ml +++ b/testsuite/tests/tool-ocaml/t210-setfield3.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t211-setfield.ml b/testsuite/tests/tool-ocaml/t211-setfield.ml index 21730fae0b..f935b7e555 100644 --- a/testsuite/tests/tool-ocaml/t211-setfield.ml +++ b/testsuite/tests/tool-ocaml/t211-setfield.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t220-assign.ml b/testsuite/tests/tool-ocaml/t220-assign.ml index 0044f89e30..26c6287cb2 100644 --- a/testsuite/tests/tool-ocaml/t220-assign.ml +++ b/testsuite/tests/tool-ocaml/t220-assign.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t230-check_signals.ml b/testsuite/tests/tool-ocaml/t230-check_signals.ml index d027d690be..3df0a96759 100644 --- a/testsuite/tests/tool-ocaml/t230-check_signals.ml +++ b/testsuite/tests/tool-ocaml/t230-check_signals.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t240-c_call1.ml b/testsuite/tests/tool-ocaml/t240-c_call1.ml index 89758f5014..a5feaebb92 100644 --- a/testsuite/tests/tool-ocaml/t240-c_call1.ml +++ b/testsuite/tests/tool-ocaml/t240-c_call1.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t240-c_call2.ml b/testsuite/tests/tool-ocaml/t240-c_call2.ml index 35d3916e82..963c42eaaf 100644 --- a/testsuite/tests/tool-ocaml/t240-c_call2.ml +++ b/testsuite/tests/tool-ocaml/t240-c_call2.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t240-c_call3.ml b/testsuite/tests/tool-ocaml/t240-c_call3.ml index f98ed86f2e..994b00f09c 100644 --- a/testsuite/tests/tool-ocaml/t240-c_call3.ml +++ b/testsuite/tests/tool-ocaml/t240-c_call3.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t240-c_call4.ml b/testsuite/tests/tool-ocaml/t240-c_call4.ml index e5a47342a2..24fa8a4ee7 100644 --- a/testsuite/tests/tool-ocaml/t240-c_call4.ml +++ b/testsuite/tests/tool-ocaml/t240-c_call4.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t240-c_call5.ml b/testsuite/tests/tool-ocaml/t240-c_call5.ml index 14a5954a9f..e55a454edf 100644 --- a/testsuite/tests/tool-ocaml/t240-c_call5.ml +++ b/testsuite/tests/tool-ocaml/t240-c_call5.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t250-closurerec-1.ml b/testsuite/tests/tool-ocaml/t250-closurerec-1.ml index d8e3169f6d..3285c5c96a 100644 --- a/testsuite/tests/tool-ocaml/t250-closurerec-1.ml +++ b/testsuite/tests/tool-ocaml/t250-closurerec-1.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t250-closurerec-2.ml b/testsuite/tests/tool-ocaml/t250-closurerec-2.ml index 4ddfd208eb..cd1e1f89dd 100644 --- a/testsuite/tests/tool-ocaml/t250-closurerec-2.ml +++ b/testsuite/tests/tool-ocaml/t250-closurerec-2.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t251-pushoffsetclosure0.ml b/testsuite/tests/tool-ocaml/t251-pushoffsetclosure0.ml index aa29928be4..3df568aab5 100644 --- a/testsuite/tests/tool-ocaml/t251-pushoffsetclosure0.ml +++ b/testsuite/tests/tool-ocaml/t251-pushoffsetclosure0.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t251-pushoffsetclosure2.ml b/testsuite/tests/tool-ocaml/t251-pushoffsetclosure2.ml index c84eea3774..9304ee1668 100644 --- a/testsuite/tests/tool-ocaml/t251-pushoffsetclosure2.ml +++ b/testsuite/tests/tool-ocaml/t251-pushoffsetclosure2.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t251-pushoffsetclosurem2.ml b/testsuite/tests/tool-ocaml/t251-pushoffsetclosurem2.ml index bc19d6fb45..bb70ea2811 100644 --- a/testsuite/tests/tool-ocaml/t251-pushoffsetclosurem2.ml +++ b/testsuite/tests/tool-ocaml/t251-pushoffsetclosurem2.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t252-pushoffsetclosure.ml b/testsuite/tests/tool-ocaml/t252-pushoffsetclosure.ml index dee93f84dc..1c949dde9f 100644 --- a/testsuite/tests/tool-ocaml/t252-pushoffsetclosure.ml +++ b/testsuite/tests/tool-ocaml/t252-pushoffsetclosure.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t253-offsetclosure0.ml b/testsuite/tests/tool-ocaml/t253-offsetclosure0.ml index 092f755a75..14f7bb92ae 100644 --- a/testsuite/tests/tool-ocaml/t253-offsetclosure0.ml +++ b/testsuite/tests/tool-ocaml/t253-offsetclosure0.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t253-offsetclosure2.ml b/testsuite/tests/tool-ocaml/t253-offsetclosure2.ml index 977574ded2..46769674fe 100644 --- a/testsuite/tests/tool-ocaml/t253-offsetclosure2.ml +++ b/testsuite/tests/tool-ocaml/t253-offsetclosure2.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t253-offsetclosurem2.ml b/testsuite/tests/tool-ocaml/t253-offsetclosurem2.ml index 69b2f13915..16ada804db 100644 --- a/testsuite/tests/tool-ocaml/t253-offsetclosurem2.ml +++ b/testsuite/tests/tool-ocaml/t253-offsetclosurem2.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t254-offsetclosure.ml b/testsuite/tests/tool-ocaml/t254-offsetclosure.ml index 1bf10ceef5..a40f94152d 100644 --- a/testsuite/tests/tool-ocaml/t254-offsetclosure.ml +++ b/testsuite/tests/tool-ocaml/t254-offsetclosure.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t260-offsetref.ml b/testsuite/tests/tool-ocaml/t260-offsetref.ml index 2884f468b9..4dd2d0f971 100644 --- a/testsuite/tests/tool-ocaml/t260-offsetref.ml +++ b/testsuite/tests/tool-ocaml/t260-offsetref.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t270-push_retaddr.ml b/testsuite/tests/tool-ocaml/t270-push_retaddr.ml index 137d668c32..8a56844657 100644 --- a/testsuite/tests/tool-ocaml/t270-push_retaddr.ml +++ b/testsuite/tests/tool-ocaml/t270-push_retaddr.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t300-getmethod.ml b/testsuite/tests/tool-ocaml/t300-getmethod.ml index c860060479..da4c46ea12 100644 --- a/testsuite/tests/tool-ocaml/t300-getmethod.ml +++ b/testsuite/tests/tool-ocaml/t300-getmethod.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t301-object.ml b/testsuite/tests/tool-ocaml/t301-object.ml index 1d035a4a0b..dc170ae97c 100644 --- a/testsuite/tests/tool-ocaml/t301-object.ml +++ b/testsuite/tests/tool-ocaml/t301-object.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) (**** file testinterp/t301-object.ml diff --git a/testsuite/tests/tool-ocaml/t310-alloc-1.ml b/testsuite/tests/tool-ocaml/t310-alloc-1.ml index 7021eda5a2..5f57c1e206 100644 --- a/testsuite/tests/tool-ocaml/t310-alloc-1.ml +++ b/testsuite/tests/tool-ocaml/t310-alloc-1.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t310-alloc-2.ml b/testsuite/tests/tool-ocaml/t310-alloc-2.ml index 4118a737bd..a2f31d4a08 100644 --- a/testsuite/tests/tool-ocaml/t310-alloc-2.ml +++ b/testsuite/tests/tool-ocaml/t310-alloc-2.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t320-gc-1.ml b/testsuite/tests/tool-ocaml/t320-gc-1.ml index be95ac9e17..4c8f4bc94e 100644 --- a/testsuite/tests/tool-ocaml/t320-gc-1.ml +++ b/testsuite/tests/tool-ocaml/t320-gc-1.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t320-gc-2.ml b/testsuite/tests/tool-ocaml/t320-gc-2.ml index 54203e9e72..39678f8f7b 100644 --- a/testsuite/tests/tool-ocaml/t320-gc-2.ml +++ b/testsuite/tests/tool-ocaml/t320-gc-2.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t320-gc-3.ml b/testsuite/tests/tool-ocaml/t320-gc-3.ml index c9b4e49b3e..e3653c29c8 100644 --- a/testsuite/tests/tool-ocaml/t320-gc-3.ml +++ b/testsuite/tests/tool-ocaml/t320-gc-3.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t330-compact-1.ml b/testsuite/tests/tool-ocaml/t330-compact-1.ml index fb58c1f859..a0a8838104 100644 --- a/testsuite/tests/tool-ocaml/t330-compact-1.ml +++ b/testsuite/tests/tool-ocaml/t330-compact-1.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t330-compact-2.ml b/testsuite/tests/tool-ocaml/t330-compact-2.ml index d466b1a246..9ef3a2acba 100644 --- a/testsuite/tests/tool-ocaml/t330-compact-2.ml +++ b/testsuite/tests/tool-ocaml/t330-compact-2.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t330-compact-3.ml b/testsuite/tests/tool-ocaml/t330-compact-3.ml index 490b686ce6..95dfc4c18e 100644 --- a/testsuite/tests/tool-ocaml/t330-compact-3.ml +++ b/testsuite/tests/tool-ocaml/t330-compact-3.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t330-compact-4.ml b/testsuite/tests/tool-ocaml/t330-compact-4.ml index e27be14bb1..a0aabcc6fd 100644 --- a/testsuite/tests/tool-ocaml/t330-compact-4.ml +++ b/testsuite/tests/tool-ocaml/t330-compact-4.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t340-weak.ml b/testsuite/tests/tool-ocaml/t340-weak.ml index 6c3d26e2f3..596278d393 100644 --- a/testsuite/tests/tool-ocaml/t340-weak.ml +++ b/testsuite/tests/tool-ocaml/t340-weak.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t350-heapcheck.ml b/testsuite/tests/tool-ocaml/t350-heapcheck.ml index bf3d137aaa..3255cf9b84 100644 --- a/testsuite/tests/tool-ocaml/t350-heapcheck.ml +++ b/testsuite/tests/tool-ocaml/t350-heapcheck.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t360-stacks-1.ml b/testsuite/tests/tool-ocaml/t360-stacks-1.ml index b952c18a8f..48c116c353 100644 --- a/testsuite/tests/tool-ocaml/t360-stacks-1.ml +++ b/testsuite/tests/tool-ocaml/t360-stacks-1.ml @@ -1,9 +1,9 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocaml/t360-stacks-2.ml b/testsuite/tests/tool-ocaml/t360-stacks-2.ml index ee73fa3dd6..1f632d7f7d 100644 --- a/testsuite/tests/tool-ocaml/t360-stacks-2.ml +++ b/testsuite/tests/tool-ocaml/t360-stacks-2.ml @@ -1,10 +1,10 @@ (* TEST -include tool-ocaml-lib -flags = "-w -a" -ocaml_script_as_argument = "true" -ocamlrunparam = "l=1000000" -* setup-ocaml-build-env -** ocaml + include tool-ocaml-lib; + flags = "-w -a"; + ocaml_script_as_argument = "true"; + ocamlrunparam = "l=1000000"; + setup-ocaml-build-env; + ocaml; *) open Lib;; diff --git a/testsuite/tests/tool-ocamlc-compat32/compat32.ml b/testsuite/tests/tool-ocamlc-compat32/compat32.ml index 8b09d8ab66..aca044847b 100644 --- a/testsuite/tests/tool-ocamlc-compat32/compat32.ml +++ b/testsuite/tests/tool-ocamlc-compat32/compat32.ml @@ -1,29 +1,29 @@ (* TEST - * arch64 - ** setup-ocamlc.byte-build-env - *** ocamlc.byte - compile_only = "true" - flags = "-compat-32" - ocamlc_byte_exit_status = "2" - **** ocamlc.byte - ocamlc_byte_exit_status = "0" - flags = "" - ***** ocamlc.byte - compile_only = "false" - all_modules = "compat32.cmo" - flags = "-compat-32 -a" - program = "compat32.cma" - ocamlc_byte_exit_status = "2" - ****** ocamlc.byte - flags = "-a" - program = "compat32.cma" - ocamlc_byte_exit_status = "0" - ******* ocamlc.byte - all_modules = "compat32.cma" - flags = "-compat-32 -linkall" - program = "compat32.byte" - ocamlc_byte_exit_status = "2" - ******** check-ocamlc.byte-output + arch64; + setup-ocamlc.byte-build-env; + compile_only = "true"; + flags = "-compat-32"; + ocamlc_byte_exit_status = "2"; + ocamlc.byte; + ocamlc_byte_exit_status = "0"; + flags = ""; + ocamlc.byte; + compile_only = "false"; + all_modules = "compat32.cmo"; + flags = "-compat-32 -a"; + program = "compat32.cma"; + ocamlc_byte_exit_status = "2"; + ocamlc.byte; + flags = "-a"; + program = "compat32.cma"; + ocamlc_byte_exit_status = "0"; + ocamlc.byte; + all_modules = "compat32.cma"; + flags = "-compat-32 -linkall"; + program = "compat32.byte"; + ocamlc_byte_exit_status = "2"; + ocamlc.byte; + check-ocamlc.byte-output; *) let a = 0xffffffffffff diff --git a/testsuite/tests/tool-ocamlc-error-cleanup/test.ml b/testsuite/tests/tool-ocamlc-error-cleanup/test.ml index 0624a6a8a9..f668d172a9 100644 --- a/testsuite/tests/tool-ocamlc-error-cleanup/test.ml +++ b/testsuite/tests/tool-ocamlc-error-cleanup/test.ml @@ -1,12 +1,12 @@ (* TEST -* setup-ocamlc.byte-build-env -compiler_output = "compiler-output.raw" -** ocamlc.byte -all_modules = "test.ml" -flags = "-warn-error +A" -ocamlc_byte_exit_status = "2" -*** script -script = "sh ${test_source_directory}/check-error-cleanup.sh" + compiler_output = "compiler-output.raw"; + setup-ocamlc.byte-build-env; + all_modules = "test.ml"; + flags = "-warn-error +A"; + ocamlc_byte_exit_status = "2"; + ocamlc.byte; + script = "sh ${test_source_directory}/check-error-cleanup.sh"; + script; *) (* Regression test for MPR#7918 *) diff --git a/testsuite/tests/tool-ocamlc-open/tool-ocamlc-open-error.ml b/testsuite/tests/tool-ocamlc-open/tool-ocamlc-open-error.ml index e965ca4385..cad238d97c 100644 --- a/testsuite/tests/tool-ocamlc-open/tool-ocamlc-open-error.ml +++ b/testsuite/tests/tool-ocamlc-open/tool-ocamlc-open-error.ml @@ -1,7 +1,7 @@ (* TEST -* setup-ocamlc.byte-build-env -** ocamlc.byte -flags = "-open F(" -ocamlc_byte_exit_status = "2" -*** check-ocamlc.byte-output + setup-ocamlc.byte-build-env; + flags = "-open F("; + ocamlc_byte_exit_status = "2"; + ocamlc.byte; + check-ocamlc.byte-output; *) diff --git a/testsuite/tests/tool-ocamlc-open/tool-ocamlc-open.ml b/testsuite/tests/tool-ocamlc-open/tool-ocamlc-open.ml index 9485a681e8..f7c275dd92 100644 --- a/testsuite/tests/tool-ocamlc-open/tool-ocamlc-open.ml +++ b/testsuite/tests/tool-ocamlc-open/tool-ocamlc-open.ml @@ -1,10 +1,10 @@ (* TEST -readonly_files = "a.ml b.ml" -* setup-ocamlc.byte-build-env -** ocamlc.byte -module = "a.ml" -*** ocamlc.byte -module = "b.ml" -flags = "-open A.M" -**** check-ocamlc.byte-output + readonly_files = "a.ml b.ml"; + setup-ocamlc.byte-build-env; + module = "a.ml"; + ocamlc.byte; + module = "b.ml"; + flags = "-open A.M"; + ocamlc.byte; + check-ocamlc.byte-output; *) diff --git a/testsuite/tests/tool-ocamlc-stop-after/stop_after_lambda.ml b/testsuite/tests/tool-ocamlc-stop-after/stop_after_lambda.ml index e018d17ce6..e1c2b58670 100644 --- a/testsuite/tests/tool-ocamlc-stop-after/stop_after_lambda.ml +++ b/testsuite/tests/tool-ocamlc-stop-after/stop_after_lambda.ml @@ -1,9 +1,9 @@ (* TEST -* setup-ocamlc.byte-build-env -** ocamlc.byte - flags = "-dlambda -stop-after lambda -nopervasives " - ocamlc_byte_exit_status = "0" -*** check-ocamlc.byte-output + setup-ocamlc.byte-build-env; + flags = "-dlambda -stop-after lambda -nopervasives "; + ocamlc_byte_exit_status = "0"; + ocamlc.byte; + check-ocamlc.byte-output; *) external p : int -> unit = "" diff --git a/testsuite/tests/tool-ocamlc-stop-after/stop_after_parsing_impl.ml b/testsuite/tests/tool-ocamlc-stop-after/stop_after_parsing_impl.ml index 3276733c51..0029d7b0ff 100644 --- a/testsuite/tests/tool-ocamlc-stop-after/stop_after_parsing_impl.ml +++ b/testsuite/tests/tool-ocamlc-stop-after/stop_after_parsing_impl.ml @@ -1,12 +1,20 @@ -(* TEST -* setup-ocamlc.byte-build-env -** ocamlc.byte - flags = "-stop-after parsing -dparsetree" - ocamlc_byte_exit_status = "0" -*** check-ocamlc.byte-output +(* TEST_BELOW +Filler_text_added_to_pr +eserve_locatio +ns_while_translating_from_old_syntax__Filler_ +text_added_to_preserve_locations_ +while_translating_from_old_s *) (* we intentionally write ill-typed output; if `-stop-after parsing` was not supported properly, the test would fail with an error *) let _ = (1 + "true") + x + +(* TEST + setup-ocamlc.byte-build-env; + flags = "-stop-after parsing -dparsetree"; + ocamlc_byte_exit_status = "0"; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/tool-ocamlc-stop-after/stop_after_parsing_intf.mli b/testsuite/tests/tool-ocamlc-stop-after/stop_after_parsing_intf.mli index 328a78d47f..802fe9abf2 100644 --- a/testsuite/tests/tool-ocamlc-stop-after/stop_after_parsing_intf.mli +++ b/testsuite/tests/tool-ocamlc-stop-after/stop_after_parsing_intf.mli @@ -1,12 +1,20 @@ -(* TEST -* setup-ocamlc.byte-build-env -** ocamlc.byte - flags = "-stop-after parsing -dparsetree" - ocamlc_byte_exit_status = "0" -*** check-ocamlc.byte-output +(* TEST_BELOW +Filler_text_added_to_pr +eserve_locatio +ns_while_translating_from_old_syntax__Filler_ +text_added_to_preserve_locations_ +while_translating_from_old_s *) (* we intentionally write ill-typed output; if `-stop-after parsing` was not supported properly, the test would fail with an error *) val x : Module_that_does_not_exists.type_that_does_not_exists + +(* TEST + setup-ocamlc.byte-build-env; + flags = "-stop-after parsing -dparsetree"; + ocamlc_byte_exit_status = "0"; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/tool-ocamlc-stop-after/stop_after_scheduling.ml b/testsuite/tests/tool-ocamlc-stop-after/stop_after_scheduling.ml index c5eae2bb41..d4344f8ba1 100644 --- a/testsuite/tests/tool-ocamlc-stop-after/stop_after_scheduling.ml +++ b/testsuite/tests/tool-ocamlc-stop-after/stop_after_scheduling.ml @@ -1,14 +1,14 @@ (* TEST -* setup-ocamlc.byte-build-env -compiler_output = "compiler-output.raw" -** ocamlc.byte - flags = "-stop-after scheduling" - ocamlc_byte_exit_status = "2" -*** script - script = "sh ${test_source_directory}/stop_after_scheduling.sh" - output = "compiler-output" -**** check-ocamlc.byte-output -compiler_output = "compiler-output" + compiler_output = "compiler-output.raw"; + setup-ocamlc.byte-build-env; + flags = "-stop-after scheduling"; + ocamlc_byte_exit_status = "2"; + ocamlc.byte; + script = "sh ${test_source_directory}/stop_after_scheduling.sh"; + output = "compiler-output"; + script; + compiler_output = "compiler-output"; + check-ocamlc.byte-output; *) (* this file is just a test driver, the test does not contain real OCaml code *) diff --git a/testsuite/tests/tool-ocamlc-stop-after/stop_after_typing_impl.ml b/testsuite/tests/tool-ocamlc-stop-after/stop_after_typing_impl.ml index f739509551..2cf68dbd28 100644 --- a/testsuite/tests/tool-ocamlc-stop-after/stop_after_typing_impl.ml +++ b/testsuite/tests/tool-ocamlc-stop-after/stop_after_typing_impl.ml @@ -1,9 +1,9 @@ -(* TEST -* setup-ocamlc.byte-build-env -** ocamlc.byte - flags = "-stop-after typing -dno-unique-ids -dtypedtree" - ocamlc_byte_exit_status = "0" -*** check-ocamlc.byte-output +(* TEST_BELOW +Filler_text_added_to_pr +eserve_locatio +ns_while_translating_from_old_syntax__Filler_text_added_to_p +reserve_locations_while_translati +ng_from_old_syntax__Filler_t *) (* we intentionally write an output that is type-correct @@ -11,3 +11,11 @@ due to the incorrect type given to the %apply compiler primitive. *) external apply: int -> int = "%apply" + +(* TEST + setup-ocamlc.byte-build-env; + flags = "-stop-after typing -dno-unique-ids -dtypedtree"; + ocamlc_byte_exit_status = "0"; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/tool-ocamldep-modalias/main.ml b/testsuite/tests/tool-ocamldep-modalias/main.ml index 801fa03339..18fe38e9e8 100644 --- a/testsuite/tests/tool-ocamldep-modalias/main.ml +++ b/testsuite/tests/tool-ocamldep-modalias/main.ml @@ -1,137 +1,134 @@ (* TEST - -readonly_files = "A.ml B.ml C.ml D.ml lib_impl.ml lib.mli \ - Makefile.build Makefile.build2" - -set sources = "A.ml B.ml C.ml D.ml" -set links = "LibA.ml LibB.ml LibC.ml LibD.ml" -set stdlib = "-nostdlib -I ${ocamlsrcdir}/stdlib" -set OCAMLC = "${ocamlrun} ${ocamlc_byte} ${stdlib}" -set OCAMLOPT = "${ocamlrun} ${ocamlopt_byte} ${stdlib}" - -* setup-ocamlc.byte-build-env -compiler_directory_suffix = ".depend.mk" -compiler_output = "${test_build_directory}/depend.mk" -** copy -src = "A.ml" -dst = "LibA.ml" -*** copy -src = "B.ml" -dst = "LibB.ml" -**** copy -src = "C.ml" -dst = "LibC.ml" -***** copy -src = "D.ml" -dst = "LibD.ml" -****** copy -src = "lib_impl.ml" -dst = "lib.ml" -******* ocamlc.byte -commandline = "-depend -as-map lib.ml lib.mli" -******** ocamlc.byte -commandline = "-depend -map lib.ml -open Lib ${links}" -********* check-ocamlc.byte-output -compiler_reference = "${test_source_directory}/depend.mk.reference" -********** hasunix -*********** script -script = "rm -f ${links}" -************ script -script = "${MAKE} -f Makefile.build byte" -************* native-compiler -************** script -script = "${MAKE} -f Makefile.build opt" - -* setup-ocamlc.byte-build-env -compiler_directory_suffix = ".depend.mk2" -compiler_output = "${test_build_directory}/depend.mk2" -** copy -src = "A.ml" -dst = "LibA.ml" -*** copy -src = "B.ml" -dst = "LibB.ml" -**** copy -src = "C.ml" -dst = "LibC.ml" -***** copy -src = "D.ml" -dst = "LibD.ml" -****** ocamlc.byte -commandline = "-depend -map lib.mli -open Lib ${links}" -******* check-ocamlc.byte-output -compiler_reference = "${test_source_directory}/depend.mk2.reference" -******** hasunix -********* script -script = "rm -f ${links}" -********** script -script = "${MAKE} -f Makefile.build2 byte" -*********** native-compiler -************ script -script = "${MAKE} -f Makefile.build2 opt" - -* setup-ocamlc.byte-build-env -compiler_directory_suffix = ".depend.mod" -** copy -src = "A.ml" -dst = "LibA.ml" -*** copy -src = "B.ml" -dst = "LibB.ml" -**** copy -src = "C.ml" -dst = "LibC.ml" -***** copy -src = "D.ml" -dst = "LibD.ml" -****** copy -src = "lib_impl.ml" -dst = "lib.ml" -******* ocamlc.byte -commandline = "-depend -as-map -modules lib.ml lib.mli" -******** ocamlc.byte -commandline = "-depend -modules -map lib.ml -open Lib ${links}" -********* check-ocamlc.byte-output -compiler_reference = "${test_source_directory}/depend.mod.reference" - -* setup-ocamlc.byte-build-env -compiler_directory_suffix = ".depend.mod2" -** copy -src = "A.ml" -dst = "LibA.ml" -*** copy -src = "B.ml" -dst = "LibB.ml" -**** copy -src = "C.ml" -dst = "LibC.ml" -***** copy -src = "D.ml" -dst = "LibD.ml" -****** ocamlc.byte -commandline = "-depend -modules -map lib.mli ${links}" -******* check-ocamlc.byte-output -compiler_reference = "${test_source_directory}/depend.mod2.reference" - -* setup-ocamlc.byte-build-env -compiler_directory_suffix = ".depend.mod3" -** copy -src = "A.ml" -dst = "LibA.ml" -*** copy -src = "B.ml" -dst = "LibB.ml" -**** copy -src = "C.ml" -dst = "LibC.ml" -***** copy -src = "D.ml" -dst = "LibD.ml" -****** ocamlc.byte -commandline = "-depend -modules -as-map -map lib.mli -open Lib ${links}" -******* check-ocamlc.byte-output -compiler_reference = "${test_source_directory}/depend.mod3.reference" - + readonly_files = "A.ml B.ml C.ml D.ml lib_impl.ml lib.mli Makefile.build Makefile.build2"; + set sources = "A.ml B.ml C.ml D.ml"; + set links = "LibA.ml LibB.ml LibC.ml LibD.ml"; + set stdlib = "-nostdlib -I ${ocamlsrcdir}/stdlib"; + set OCAMLC = "${ocamlrun} ${ocamlc_byte} ${stdlib}"; + set OCAMLOPT = "${ocamlrun} ${ocamlopt_byte} ${stdlib}"; + { + compiler_directory_suffix = ".depend.mk"; + compiler_output = "${test_build_directory}/depend.mk"; + setup-ocamlc.byte-build-env; + src = "A.ml"; + dst = "LibA.ml"; + copy; + src = "B.ml"; + dst = "LibB.ml"; + copy; + src = "C.ml"; + dst = "LibC.ml"; + copy; + src = "D.ml"; + dst = "LibD.ml"; + copy; + src = "lib_impl.ml"; + dst = "lib.ml"; + copy; + commandline = "-depend -as-map lib.ml lib.mli"; + ocamlc.byte; + commandline = "-depend -map lib.ml -open Lib ${links}"; + ocamlc.byte; + compiler_reference = "${test_source_directory}/depend.mk.reference"; + check-ocamlc.byte-output; + hasunix; + script = "rm -f ${links}"; + script; + script = "${MAKE} -f Makefile.build byte"; + script; + native-compiler; + script = "${MAKE} -f Makefile.build opt"; + script; + }{ + compiler_directory_suffix = ".depend.mk2"; + compiler_output = "${test_build_directory}/depend.mk2"; + setup-ocamlc.byte-build-env; + src = "A.ml"; + dst = "LibA.ml"; + copy; + src = "B.ml"; + dst = "LibB.ml"; + copy; + src = "C.ml"; + dst = "LibC.ml"; + copy; + src = "D.ml"; + dst = "LibD.ml"; + copy; + commandline = "-depend -map lib.mli -open Lib ${links}"; + ocamlc.byte; + compiler_reference = "${test_source_directory}/depend.mk2.reference"; + check-ocamlc.byte-output; + hasunix; + script = "rm -f ${links}"; + script; + script = "${MAKE} -f Makefile.build2 byte"; + script; + native-compiler; + script = "${MAKE} -f Makefile.build2 opt"; + script; + }{ + compiler_directory_suffix = ".depend.mod"; + setup-ocamlc.byte-build-env; + src = "A.ml"; + dst = "LibA.ml"; + copy; + src = "B.ml"; + dst = "LibB.ml"; + copy; + src = "C.ml"; + dst = "LibC.ml"; + copy; + src = "D.ml"; + dst = "LibD.ml"; + copy; + src = "lib_impl.ml"; + dst = "lib.ml"; + copy; + commandline = "-depend -as-map -modules lib.ml lib.mli"; + ocamlc.byte; + commandline = "-depend -modules -map lib.ml -open Lib ${links}"; + ocamlc.byte; + compiler_reference = "${test_source_directory}/depend.mod.reference"; + check-ocamlc.byte-output; + }{ + compiler_directory_suffix = ".depend.mod2"; + setup-ocamlc.byte-build-env; + src = "A.ml"; + dst = "LibA.ml"; + copy; + src = "B.ml"; + dst = "LibB.ml"; + copy; + src = "C.ml"; + dst = "LibC.ml"; + copy; + src = "D.ml"; + dst = "LibD.ml"; + copy; + commandline = "-depend -modules -map lib.mli ${links}"; + ocamlc.byte; + compiler_reference = "${test_source_directory}/depend.mod2.reference"; + check-ocamlc.byte-output; + }{ + compiler_directory_suffix = ".depend.mod3"; + setup-ocamlc.byte-build-env; + src = "A.ml"; + dst = "LibA.ml"; + copy; + src = "B.ml"; + dst = "LibB.ml"; + copy; + src = "C.ml"; + dst = "LibC.ml"; + copy; + src = "D.ml"; + dst = "LibD.ml"; + copy; + commandline = "-depend -modules -as-map -map lib.mli -open Lib ${links}"; + ocamlc.byte; + compiler_reference = "${test_source_directory}/depend.mod3.reference"; + check-ocamlc.byte-output; + } *) open Lib diff --git a/testsuite/tests/tool-ocamldep-shadowing/a.ml b/testsuite/tests/tool-ocamldep-shadowing/a.ml index 066d4b5200..5da9c53937 100644 --- a/testsuite/tests/tool-ocamldep-shadowing/a.ml +++ b/testsuite/tests/tool-ocamldep-shadowing/a.ml @@ -1,12 +1,10 @@ (* TEST - -subdirectories = "dir1 dir2" - -* setup-ocamlc.byte-build-env -** ocamlc.byte -commandline = "-depend -slash -I dir1 -I dir2 a.ml" -*** check-ocamlc.byte-output -compiler_reference = "${test_source_directory}/a.reference" + subdirectories = "dir1 dir2"; + setup-ocamlc.byte-build-env; + commandline = "-depend -slash -I dir1 -I dir2 a.ml"; + ocamlc.byte; + compiler_reference = "${test_source_directory}/a.reference"; + check-ocamlc.byte-output; *) include B diff --git a/testsuite/tests/tool-ocamldoc-open/main.ml b/testsuite/tests/tool-ocamldoc-open/main.ml index 4dca4e546d..f76734e67e 100644 --- a/testsuite/tests/tool-ocamldoc-open/main.ml +++ b/testsuite/tests/tool-ocamldoc-open/main.ml @@ -1,8 +1,8 @@ (* TEST - modules = "inner.ml alias.ml" - * ocamldoc - ocamldoc_backend="latex" - ocamldoc_flags=" -open Alias.Container -open Aliased_inner " + modules = "inner.ml alias.ml"; + ocamldoc_backend = "latex"; + ocamldoc_flags = " -open Alias.Container -open Aliased_inner "; + ocamldoc; *) (** Documentation test *) diff --git a/testsuite/tests/tool-ocamldoc/Alert_toplevel.mli b/testsuite/tests/tool-ocamldoc/Alert_toplevel.mli index 4b67c2d769..73a9e74625 100644 --- a/testsuite/tests/tool-ocamldoc/Alert_toplevel.mli +++ b/testsuite/tests/tool-ocamldoc/Alert_toplevel.mli @@ -1,5 +1,5 @@ (* TEST - * ocamldoc with html + ocamldoc with html; *) (** There's a top-comment before. *) diff --git a/testsuite/tests/tool-ocamldoc/Alert_toplevel2.mli b/testsuite/tests/tool-ocamldoc/Alert_toplevel2.mli index a31bab4304..9284a7db66 100644 --- a/testsuite/tests/tool-ocamldoc/Alert_toplevel2.mli +++ b/testsuite/tests/tool-ocamldoc/Alert_toplevel2.mli @@ -1,5 +1,5 @@ (* TEST - * ocamldoc with html + ocamldoc with html; *) [@@@alert deprecated "foo"] diff --git a/testsuite/tests/tool-ocamldoc/Alerts.mli b/testsuite/tests/tool-ocamldoc/Alerts.mli index 95846b0a19..c2d0a44f31 100644 --- a/testsuite/tests/tool-ocamldoc/Alerts.mli +++ b/testsuite/tests/tool-ocamldoc/Alerts.mli @@ -1,5 +1,5 @@ (* TEST - * ocamldoc with html + ocamldoc with html; *) (** Test the rendering of alerts. *) diff --git a/testsuite/tests/tool-ocamldoc/Alerts_impl.ml b/testsuite/tests/tool-ocamldoc/Alerts_impl.ml index db38c1e573..e542af37d1 100644 --- a/testsuite/tests/tool-ocamldoc/Alerts_impl.ml +++ b/testsuite/tests/tool-ocamldoc/Alerts_impl.ml @@ -1,6 +1,6 @@ (* TEST - * ocamldoc with html - *) + ocamldoc with html; +*) (** Alerts from implementation. *) diff --git a/testsuite/tests/tool-ocamldoc/Documentation_tags.mli b/testsuite/tests/tool-ocamldoc/Documentation_tags.mli index 0dadce6610..cffb06626d 100644 --- a/testsuite/tests/tool-ocamldoc/Documentation_tags.mli +++ b/testsuite/tests/tool-ocamldoc/Documentation_tags.mli @@ -1,5 +1,5 @@ (* TEST - * ocamldoc with html + ocamldoc with html; *) (** Test the html rendering of ocamldoc documentation tags *) diff --git a/testsuite/tests/tool-ocamldoc/Entities.ml b/testsuite/tests/tool-ocamldoc/Entities.ml index 218817eed8..ce48d6755b 100644 --- a/testsuite/tests/tool-ocamldoc/Entities.ml +++ b/testsuite/tests/tool-ocamldoc/Entities.ml @@ -1,5 +1,5 @@ (* TEST - * ocamldoc with html + ocamldoc with html; *) type ul diff --git a/testsuite/tests/tool-ocamldoc/Extensible_variant.ml b/testsuite/tests/tool-ocamldoc/Extensible_variant.ml index f459fa276b..7202a8475c 100644 --- a/testsuite/tests/tool-ocamldoc/Extensible_variant.ml +++ b/testsuite/tests/tool-ocamldoc/Extensible_variant.ml @@ -1,5 +1,5 @@ (* TEST - * ocamldoc with latex + ocamldoc with latex; *) (** Testing display of extensible variant types and exceptions. diff --git a/testsuite/tests/tool-ocamldoc/Include_module_type_of.mli b/testsuite/tests/tool-ocamldoc/Include_module_type_of.mli index c30432d472..b33cbb5c5c 100644 --- a/testsuite/tests/tool-ocamldoc/Include_module_type_of.mli +++ b/testsuite/tests/tool-ocamldoc/Include_module_type_of.mli @@ -1,6 +1,9 @@ (* TEST - * ocamldoc with html - * ocamldoc with latex + { + ocamldoc with html; + }{ + ocamldoc with latex; + } *) (** Test [include module type of...] variants *) diff --git a/testsuite/tests/tool-ocamldoc/Inline_records.mli b/testsuite/tests/tool-ocamldoc/Inline_records.mli index 5b4646d9e1..1f5a15e667 100644 --- a/testsuite/tests/tool-ocamldoc/Inline_records.mli +++ b/testsuite/tests/tool-ocamldoc/Inline_records.mli @@ -1,7 +1,11 @@ (* TEST - * ocamldoc with html - * ocamldoc with latex - * ocamldoc with man + { + ocamldoc with html; + }{ + ocamldoc with latex; + }{ + ocamldoc with man; + } *) (** diff --git a/testsuite/tests/tool-ocamldoc/Inline_records_bis.ml b/testsuite/tests/tool-ocamldoc/Inline_records_bis.ml index 4844aaf27a..970912b3f8 100644 --- a/testsuite/tests/tool-ocamldoc/Inline_records_bis.ml +++ b/testsuite/tests/tool-ocamldoc/Inline_records_bis.ml @@ -1,5 +1,5 @@ (* TEST - * ocamldoc with latex + ocamldoc with latex; *) (** diff --git a/testsuite/tests/tool-ocamldoc/Item_ids.mli b/testsuite/tests/tool-ocamldoc/Item_ids.mli index 878c6fef30..744fd9d239 100644 --- a/testsuite/tests/tool-ocamldoc/Item_ids.mli +++ b/testsuite/tests/tool-ocamldoc/Item_ids.mli @@ -1,5 +1,5 @@ (* TEST - * ocamldoc with html + ocamldoc with html; *) (** Check that all toplevel items are given a unique id. *) diff --git a/testsuite/tests/tool-ocamldoc/Level_0.mli b/testsuite/tests/tool-ocamldoc/Level_0.mli index f7ac2a888e..3bd9aea977 100644 --- a/testsuite/tests/tool-ocamldoc/Level_0.mli +++ b/testsuite/tests/tool-ocamldoc/Level_0.mli @@ -1,5 +1,5 @@ (* TEST - * ocamldoc with latex + ocamldoc with latex; *) (** Test for level 0 headings diff --git a/testsuite/tests/tool-ocamldoc/Linebreaks.mli b/testsuite/tests/tool-ocamldoc/Linebreaks.mli index 1dce3838b8..1baf3db314 100644 --- a/testsuite/tests/tool-ocamldoc/Linebreaks.mli +++ b/testsuite/tests/tool-ocamldoc/Linebreaks.mli @@ -1,8 +1,8 @@ (* TEST - * ocamldoc with html - ** check-program-output - output="type_Linebreaks.html" - reference="${test_source_directory}/type_Linebreaks.reference" + ocamldoc with html; + output = "type_Linebreaks.html"; + reference = "${test_source_directory}/type_Linebreaks.reference"; + check-program-output; *) (** diff --git a/testsuite/tests/tool-ocamldoc/Loop.ml b/testsuite/tests/tool-ocamldoc/Loop.ml index 8428f9fc15..b3c4f6888e 100644 --- a/testsuite/tests/tool-ocamldoc/Loop.ml +++ b/testsuite/tests/tool-ocamldoc/Loop.ml @@ -1,5 +1,8 @@ (* TEST - * ocamldoc with html - * ocamldoc with latex + { + ocamldoc with html; + }{ + ocamldoc with latex; + } *) module rec A : sig type t end = B and B : sig type t = A.t end = A;; diff --git a/testsuite/tests/tool-ocamldoc/Module_whitespace.ml b/testsuite/tests/tool-ocamldoc/Module_whitespace.ml index 75c6c29274..7b3723d6cf 100644 --- a/testsuite/tests/tool-ocamldoc/Module_whitespace.ml +++ b/testsuite/tests/tool-ocamldoc/Module_whitespace.ml @@ -1,5 +1,5 @@ (* TEST - * ocamldoc with html + ocamldoc with html; *) module M = Set.Make(struct diff --git a/testsuite/tests/tool-ocamldoc/No_preamble.mli b/testsuite/tests/tool-ocamldoc/No_preamble.mli index 7d016dda22..ea8a655f19 100644 --- a/testsuite/tests/tool-ocamldoc/No_preamble.mli +++ b/testsuite/tests/tool-ocamldoc/No_preamble.mli @@ -1,5 +1,5 @@ (* TEST - * ocamldoc with html + ocamldoc with html; *) open String diff --git a/testsuite/tests/tool-ocamldoc/Paragraph.mli b/testsuite/tests/tool-ocamldoc/Paragraph.mli index 8073c7cd99..73e39e9412 100644 --- a/testsuite/tests/tool-ocamldoc/Paragraph.mli +++ b/testsuite/tests/tool-ocamldoc/Paragraph.mli @@ -1,5 +1,5 @@ (* TEST - * ocamldoc with html + ocamldoc with html; *) (** This file tests the generation of paragraph within module comments. diff --git a/testsuite/tests/tool-ocamldoc/Short_description.latex.reference b/testsuite/tests/tool-ocamldoc/Short_description.latex.reference index 4a938e4168..26241644c1 100644 --- a/testsuite/tests/tool-ocamldoc/Short_description.latex.reference +++ b/testsuite/tests/tool-ocamldoc/Short_description.latex.reference @@ -8,7 +8,7 @@ \begin{document} \tableofcontents \section{Short\_description : (* TEST - * ocamldoc with latex + ocamldoc with latex; *)} \label{Short-underscoredescription}\index{Short-underscoredescription@\verb`Short_description`} diff --git a/testsuite/tests/tool-ocamldoc/Short_description.txt b/testsuite/tests/tool-ocamldoc/Short_description.txt index e0021ea697..12a063ba60 100644 --- a/testsuite/tests/tool-ocamldoc/Short_description.txt +++ b/testsuite/tests/tool-ocamldoc/Short_description.txt @@ -1,5 +1,5 @@ (* TEST - * ocamldoc with latex + ocamldoc with latex; *) Short global description in text mode diff --git a/testsuite/tests/tool-ocamldoc/Test.mli b/testsuite/tests/tool-ocamldoc/Test.mli index b28c8e734e..cbb4aa6a21 100644 --- a/testsuite/tests/tool-ocamldoc/Test.mli +++ b/testsuite/tests/tool-ocamldoc/Test.mli @@ -1,5 +1,5 @@ (* TEST - * ocamldoc with latex + ocamldoc with latex; *) (** Ten comments for tests *) diff --git a/testsuite/tests/tool-ocamldoc/Variants.mli b/testsuite/tests/tool-ocamldoc/Variants.mli index 137a42ce6d..ba6de5b455 100644 --- a/testsuite/tests/tool-ocamldoc/Variants.mli +++ b/testsuite/tests/tool-ocamldoc/Variants.mli @@ -1,6 +1,9 @@ (* TEST - * ocamldoc with html - * ocamldoc with latex + { + ocamldoc with html; + }{ + ocamldoc with latex; + } *) (** This test is here to check the latex code generated for variants *) diff --git a/testsuite/tests/tool-ocamldoc/latex_ref.mli b/testsuite/tests/tool-ocamldoc/latex_ref.mli index 8424aa891f..9ed1a8f86a 100644 --- a/testsuite/tests/tool-ocamldoc/latex_ref.mli +++ b/testsuite/tests/tool-ocamldoc/latex_ref.mli @@ -1,5 +1,5 @@ (* TEST - * ocamldoc with latex + ocamldoc with latex; *) (** Latex-only test *) diff --git a/testsuite/tests/tool-ocamldoc/t01.ml b/testsuite/tests/tool-ocamldoc/t01.ml index 1003b47f2d..9d76ba51ff 100644 --- a/testsuite/tests/tool-ocamldoc/t01.ml +++ b/testsuite/tests/tool-ocamldoc/t01.ml @@ -1,7 +1,7 @@ (* TEST - plugins="odoc_test.ml" - * ocamldoc - flags="-I ${ocamlsrcdir}/ocamldoc" + plugins = "odoc_test.ml"; + flags = "-I ${ocamlsrcdir}/ocamldoc"; + ocamldoc; *) (** Testing display of types. diff --git a/testsuite/tests/tool-ocamldoc/t02.ml b/testsuite/tests/tool-ocamldoc/t02.ml index a2280cf8f3..4dbef6c167 100644 --- a/testsuite/tests/tool-ocamldoc/t02.ml +++ b/testsuite/tests/tool-ocamldoc/t02.ml @@ -1,7 +1,7 @@ (* TEST - plugins="odoc_test.ml" - * ocamldoc - flags="-I ${ocamlsrcdir}/ocamldoc" + plugins = "odoc_test.ml"; + flags = "-I ${ocamlsrcdir}/ocamldoc"; + ocamldoc; *) module Foo = struct type u type t = int let x = 1 end;; diff --git a/testsuite/tests/tool-ocamldoc/t03.ml b/testsuite/tests/tool-ocamldoc/t03.ml index 3ee319ba02..69022bb03a 100644 --- a/testsuite/tests/tool-ocamldoc/t03.ml +++ b/testsuite/tests/tool-ocamldoc/t03.ml @@ -1,7 +1,7 @@ (* TEST - plugins="odoc_test.ml" - * ocamldoc - flags="-I ${ocamlsrcdir}/ocamldoc" + plugins = "odoc_test.ml"; + flags = "-I ${ocamlsrcdir}/ocamldoc"; + ocamldoc; *) module Foo = struct type t = int let x = 1 end;; diff --git a/testsuite/tests/tool-ocamldoc/t04.ml b/testsuite/tests/tool-ocamldoc/t04.ml index d815b4ccc0..85d1fe59ca 100644 --- a/testsuite/tests/tool-ocamldoc/t04.ml +++ b/testsuite/tests/tool-ocamldoc/t04.ml @@ -1,7 +1,7 @@ (* TEST - plugins="odoc_test.ml" - * ocamldoc - flags="-I ${ocamlsrcdir}/ocamldoc" + plugins = "odoc_test.ml"; + flags = "-I ${ocamlsrcdir}/ocamldoc"; + ocamldoc; *) (** Testing display of inline record. diff --git a/testsuite/tests/tool-ocamldoc/t05.ml b/testsuite/tests/tool-ocamldoc/t05.ml index 885dc90a32..f5fb0b98e6 100644 --- a/testsuite/tests/tool-ocamldoc/t05.ml +++ b/testsuite/tests/tool-ocamldoc/t05.ml @@ -1,7 +1,7 @@ (* TEST - plugins="odoc_test.ml" - * ocamldoc - flags="-I ${ocamlsrcdir}/ocamldoc" + plugins = "odoc_test.ml"; + flags = "-I ${ocamlsrcdir}/ocamldoc"; + ocamldoc; *) module rec A : sig type t end = B and B : sig type t = A.t end = A;; diff --git a/testsuite/tests/tool-ocamlobjinfo/question.ml b/testsuite/tests/tool-ocamlobjinfo/question.ml index 0b42dd1f9d..8689d62cd3 100644 --- a/testsuite/tests/tool-ocamlobjinfo/question.ml +++ b/testsuite/tests/tool-ocamlobjinfo/question.ml @@ -1,13 +1,13 @@ (* TEST -* shared-libraries -** setup-ocamlopt.byte-build-env -*** ocamlopt.byte -flags = "-shared" -all_modules = "question.ml" -program = "question.cmxs" -**** check-ocamlopt.byte-output -***** ocamlobjinfo -****** check-program-output + shared-libraries; + setup-ocamlopt.byte-build-env; + flags = "-shared"; + all_modules = "question.ml"; + program = "question.cmxs"; + ocamlopt.byte; + check-ocamlopt.byte-output; + ocamlobjinfo; + check-program-output; *) let answer = 42 diff --git a/testsuite/tests/tool-ocamlopt-save-ir/check_for_pack.ml b/testsuite/tests/tool-ocamlopt-save-ir/check_for_pack.ml index 610abbdc34..531aacbd7a 100644 --- a/testsuite/tests/tool-ocamlopt-save-ir/check_for_pack.ml +++ b/testsuite/tests/tool-ocamlopt-save-ir/check_for_pack.ml @@ -1,16 +1,16 @@ (* TEST - * native-compiler - ** setup-ocamlopt.byte-build-env - *** ocamlopt.byte - flags = "-save-ir-after scheduling" - ocamlopt_byte_exit_status = "0" - **** script - script = "touch empty.ml" - ***** ocamlopt.byte - flags = "-S check_for_pack.cmir-linear -for-pack foo" - module = "empty.ml" - ocamlopt_byte_exit_status = "2" - ****** check-ocamlopt.byte-output + native-compiler; + setup-ocamlopt.byte-build-env; + flags = "-save-ir-after scheduling"; + ocamlopt_byte_exit_status = "0"; + ocamlopt.byte; + script = "touch empty.ml"; + script; + flags = "-S check_for_pack.cmir-linear -for-pack foo"; + module = "empty.ml"; + ocamlopt_byte_exit_status = "2"; + ocamlopt.byte; + check-ocamlopt.byte-output; *) let foo f x = diff --git a/testsuite/tests/tool-ocamlopt-save-ir/save_ir_after_scheduling.ml b/testsuite/tests/tool-ocamlopt-save-ir/save_ir_after_scheduling.ml index 1d81597856..9d8e1e11e3 100644 --- a/testsuite/tests/tool-ocamlopt-save-ir/save_ir_after_scheduling.ml +++ b/testsuite/tests/tool-ocamlopt-save-ir/save_ir_after_scheduling.ml @@ -1,11 +1,11 @@ (* TEST - * native-compiler - ** setup-ocamlopt.byte-build-env - *** ocamlopt.byte - flags = "-save-ir-after scheduling -S" - **** check-ocamlopt.byte-output - ***** script - script = "sh ${test_source_directory}/save_ir_after_scheduling.sh" + native-compiler; + setup-ocamlopt.byte-build-env; + flags = "-save-ir-after scheduling -S"; + ocamlopt.byte; + check-ocamlopt.byte-output; + script = "sh ${test_source_directory}/save_ir_after_scheduling.sh"; + script; *) let foo f x = diff --git a/testsuite/tests/tool-ocamlopt-save-ir/save_ir_after_typing.ml b/testsuite/tests/tool-ocamlopt-save-ir/save_ir_after_typing.ml index 15c2379f7c..17c4554e52 100644 --- a/testsuite/tests/tool-ocamlopt-save-ir/save_ir_after_typing.ml +++ b/testsuite/tests/tool-ocamlopt-save-ir/save_ir_after_typing.ml @@ -1,15 +1,18 @@ (* TEST - * native-compiler - ** setup-ocamlopt.byte-build-env - compiler_output = "compiler-output.raw" - *** ocamlopt.byte - flags = "-save-ir-after typing" - ocamlopt_byte_exit_status = "2" - *** script - script = "sh ${test_source_directory}/save_ir_after_typing.sh" - output = "compiler-output" - **** check-ocamlopt.byte-output - compiler_output = "compiler-output" + native-compiler; + compiler_output = "compiler-output.raw"; + setup-ocamlopt.byte-build-env; + { + flags = "-save-ir-after typing"; + ocamlopt_byte_exit_status = "2"; + ocamlopt.byte; + }{ + script = "sh ${test_source_directory}/save_ir_after_typing.sh"; + output = "compiler-output"; + script; + compiler_output = "compiler-output"; + check-ocamlopt.byte-output; + } *) (* this file is just a test driver, the test does not contain real OCaml code *) diff --git a/testsuite/tests/tool-ocamlopt-save-ir/start_from_emit.ml b/testsuite/tests/tool-ocamlopt-save-ir/start_from_emit.ml index bac85a816f..66757e0691 100644 --- a/testsuite/tests/tool-ocamlopt-save-ir/start_from_emit.ml +++ b/testsuite/tests/tool-ocamlopt-save-ir/start_from_emit.ml @@ -1,29 +1,28 @@ (* TEST - * native-compiler - ** setup-ocamlopt.byte-build-env - *** ocamlopt.byte - flags = "-save-ir-after scheduling -stop-after scheduling" - ocamlopt_byte_exit_status = "0" - **** script - script = "touch empty.ml" - ***** ocamlopt.byte - flags = "-S start_from_emit.cmir-linear" - module = "empty.ml" - ocamlopt_byte_exit_status = "0" - ****** check-ocamlopt.byte-output - ******* script - script = "sh ${test_source_directory}/start_from_emit.sh" - ******** ocamlopt.byte - flags = "-S start_from_emit.cmir-linear -save-ir-after scheduling" - module = "empty.ml" - ocamlopt_byte_exit_status = "0" - ********* copy - src = "start_from_emit.cmir-linear" - dst = "expected.cmir_linear" - ********** check-ocamlopt.byte-output - *********** script - script = "cmp start_from_emit.cmir-linear expected.cmir_linear" - + native-compiler; + setup-ocamlopt.byte-build-env; + flags = "-save-ir-after scheduling -stop-after scheduling"; + ocamlopt_byte_exit_status = "0"; + ocamlopt.byte; + script = "touch empty.ml"; + script; + flags = "-S start_from_emit.cmir-linear"; + module = "empty.ml"; + ocamlopt_byte_exit_status = "0"; + ocamlopt.byte; + check-ocamlopt.byte-output; + script = "sh ${test_source_directory}/start_from_emit.sh"; + script; + flags = "-S start_from_emit.cmir-linear -save-ir-after scheduling"; + module = "empty.ml"; + ocamlopt_byte_exit_status = "0"; + ocamlopt.byte; + src = "start_from_emit.cmir-linear"; + dst = "expected.cmir_linear"; + copy; + check-ocamlopt.byte-output; + script = "cmp start_from_emit.cmir-linear expected.cmir_linear"; + script; *) let foo f x = diff --git a/testsuite/tests/tool-ocamlopt-stop-after/stop_after_lambda.ml b/testsuite/tests/tool-ocamlopt-stop-after/stop_after_lambda.ml index 591f3d112b..a3f08f4bfc 100644 --- a/testsuite/tests/tool-ocamlopt-stop-after/stop_after_lambda.ml +++ b/testsuite/tests/tool-ocamlopt-stop-after/stop_after_lambda.ml @@ -1,10 +1,10 @@ (* TEST -* no-flambda -** setup-ocamlopt.byte-build-env -*** ocamlopt.byte - flags = "-dlambda -stop-after lambda -nopervasives " - ocamlopt_byte_exit_status = "0" -**** check-ocamlopt.byte-output + no-flambda; + setup-ocamlopt.byte-build-env; + flags = "-dlambda -stop-after lambda -nopervasives "; + ocamlopt_byte_exit_status = "0"; + ocamlopt.byte; + check-ocamlopt.byte-output; *) (* no-flambda: the -lambda output differs with flambda, and diff --git a/testsuite/tests/tool-ocamlopt-stop-after/stop_after_scheduling.ml b/testsuite/tests/tool-ocamlopt-stop-after/stop_after_scheduling.ml index dfa97ffd68..d446248f1b 100644 --- a/testsuite/tests/tool-ocamlopt-stop-after/stop_after_scheduling.ml +++ b/testsuite/tests/tool-ocamlopt-stop-after/stop_after_scheduling.ml @@ -1,12 +1,12 @@ (* TEST - * native-compiler - ** setup-ocamlopt.byte-build-env - *** ocamlopt.byte - flags = "-stop-after scheduling -S" - ocamlopt_byte_exit_status = "0" - **** check-ocamlopt.byte-output - ***** script - script = "sh ${test_source_directory}/stop_after_scheduling.sh" + native-compiler; + setup-ocamlopt.byte-build-env; + flags = "-stop-after scheduling -S"; + ocamlopt_byte_exit_status = "0"; + ocamlopt.byte; + check-ocamlopt.byte-output; + script = "sh ${test_source_directory}/stop_after_scheduling.sh"; + script; *) (* this file is just a test driver, the test does not contain real OCaml code *) diff --git a/testsuite/tests/tool-ocamltest/norm1.ml b/testsuite/tests/tool-ocamltest/norm1.ml index ea32acffed..d4f5e418e8 100644 --- a/testsuite/tests/tool-ocamltest/norm1.ml +++ b/testsuite/tests/tool-ocamltest/norm1.ml @@ -1,5 +1,4 @@ -(* TEST - *) +(* TEST *) let () = set_binary_mode_out stdout true in (* ocamltest must normalise the \r\n *) print_string "line1\r\n"; flush stdout diff --git a/testsuite/tests/tool-ocamltest/norm2.ml b/testsuite/tests/tool-ocamltest/norm2.ml index 284e99d694..cdf4afaf96 100644 --- a/testsuite/tests/tool-ocamltest/norm2.ml +++ b/testsuite/tests/tool-ocamltest/norm2.ml @@ -1,5 +1,4 @@ -(* TEST - *) +(* TEST *) let () = set_binary_mode_out stdout true in (* ocamltest must normalise the \r\n *) print_string "line1\r\nline2\r\n"; flush stdout diff --git a/testsuite/tests/tool-ocamltest/norm3.ml b/testsuite/tests/tool-ocamltest/norm3.ml index eb7baa75ce..9818a2c3b4 100644 --- a/testsuite/tests/tool-ocamltest/norm3.ml +++ b/testsuite/tests/tool-ocamltest/norm3.ml @@ -1,5 +1,4 @@ -(* TEST - *) +(* TEST *) let () = set_binary_mode_out stdout true in (* ocamltest must normalise the \r\n but preserve the final \r *) print_string "line1\r\nline2\r"; flush stdout diff --git a/testsuite/tests/tool-ocamltest/norm4.ml b/testsuite/tests/tool-ocamltest/norm4.ml index 7b06b92228..b91b390a65 100644 --- a/testsuite/tests/tool-ocamltest/norm4.ml +++ b/testsuite/tests/tool-ocamltest/norm4.ml @@ -1,5 +1,4 @@ -(* TEST - *) +(* TEST *) let () = set_binary_mode_out stdout true in (* ocamltest must normalise the \r\n *) print_string "line1\r\nline2"; flush stdout diff --git a/testsuite/tests/tool-toplevel-invocation/test.ml b/testsuite/tests/tool-toplevel-invocation/test.ml index b5c54d5499..7951c7e2a9 100644 --- a/testsuite/tests/tool-toplevel-invocation/test.ml +++ b/testsuite/tests/tool-toplevel-invocation/test.ml @@ -1,51 +1,47 @@ (* TEST - -readonly_files = "first_arg_fail.txt last_arg_fail.txt" - -* setup-ocaml-build-env - -** ocaml -flags = "-args ${test_source_directory}/first_arg_fail.txt" -compiler_reference = "${test_source_directory}/first_arg_fail.txt.reference" -compiler_output = "${test_build_directory}/first_arg_fail.output" -ocaml_exit_status = "2" -*** check-ocaml-output - -** ocaml -flags = "-args ${test_source_directory}/indirect_first_arg_fail.txt" -compiler_reference = - "${test_source_directory}/indirect_first_arg_fail.txt.reference" -compiler_output = "${test_build_directory}/indirect_first_arg_fail.output" -ocaml_exit_status = "2" -*** check-ocaml-output - -** ocaml -flags = "-args ${test_source_directory}/indirect_last_arg_fail.txt" -compiler_reference = - "${test_source_directory}/indirect_last_arg_fail.txt.reference" -compiler_output = "${test_build_directory}/indirect_last_arg_fail.output" -ocaml_exit_status = "2" -*** check-ocaml-output - -** ocaml -flags = "-args ${test_source_directory}/last_arg_fail.txt" -compiler_reference = "${test_source_directory}/last_arg_fail.txt.reference" -compiler_output = "${test_build_directory}/last_arg_fail.output" -ocaml_exit_status = "2" -*** check-ocaml-output - -** ocaml -flags = "-args ${test_source_directory}/working_arg.txt" -compiler_reference = "${test_source_directory}/working_arg.txt.reference" -compiler_output = "${test_build_directory}/working_arg.output" -*** check-ocaml-output - -** ocaml -flags = "${test_source_directory}/print_args.ml foo bar" -compiler_reference = "${test_source_directory}/print_args.reference" -compiler_output = "${test_build_directory}/print_args.output" -*** check-ocaml-output - + readonly_files = "first_arg_fail.txt last_arg_fail.txt"; + setup-ocaml-build-env; + { + flags = "-args ${test_source_directory}/first_arg_fail.txt"; + compiler_reference = "${test_source_directory}/first_arg_fail.txt.reference"; + compiler_output = "${test_build_directory}/first_arg_fail.output"; + ocaml_exit_status = "2"; + ocaml; + check-ocaml-output; + }{ + flags = "-args ${test_source_directory}/indirect_first_arg_fail.txt"; + compiler_reference = "${test_source_directory}/indirect_first_arg_fail.txt.reference"; + compiler_output = "${test_build_directory}/indirect_first_arg_fail.output"; + ocaml_exit_status = "2"; + ocaml; + check-ocaml-output; + }{ + flags = "-args ${test_source_directory}/indirect_last_arg_fail.txt"; + compiler_reference = "${test_source_directory}/indirect_last_arg_fail.txt.reference"; + compiler_output = "${test_build_directory}/indirect_last_arg_fail.output"; + ocaml_exit_status = "2"; + ocaml; + check-ocaml-output; + }{ + flags = "-args ${test_source_directory}/last_arg_fail.txt"; + compiler_reference = "${test_source_directory}/last_arg_fail.txt.reference"; + compiler_output = "${test_build_directory}/last_arg_fail.output"; + ocaml_exit_status = "2"; + ocaml; + check-ocaml-output; + }{ + flags = "-args ${test_source_directory}/working_arg.txt"; + compiler_reference = "${test_source_directory}/working_arg.txt.reference"; + compiler_output = "${test_build_directory}/working_arg.output"; + ocaml; + check-ocaml-output; + }{ + flags = "${test_source_directory}/print_args.ml foo bar"; + compiler_reference = "${test_source_directory}/print_args.reference"; + compiler_output = "${test_build_directory}/print_args.output"; + ocaml; + check-ocaml-output; + } *) printf "Test succeeds\n";; diff --git a/testsuite/tests/tool-toplevel/error_highlighting.ml b/testsuite/tests/tool-toplevel/error_highlighting.ml index dbf3810387..eb6f98af1f 100644 --- a/testsuite/tests/tool-toplevel/error_highlighting.ml +++ b/testsuite/tests/tool-toplevel/error_highlighting.ml @@ -1,9 +1,9 @@ -(* TEST - readonly_files = "error_highlighting_use1.ml \ - error_highlighting_use2.ml \ - error_highlighting_use3.ml \ - error_highlighting_use4.ml" - * toplevel +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) let x = (1 + 2) +. 3. in ();; @@ -109,3 +109,8 @@ let x = 1 in ();; #use "error_highlighting_use2.ml";; #use "error_highlighting_use3.ml";; #use "error_highlighting_use4.ml";; + +(* TEST + readonly_files = "error_highlighting_use1.ml error_highlighting_use2.ml error_highlighting_use3.ml error_highlighting_use4.ml"; + toplevel; +*) diff --git a/testsuite/tests/tool-toplevel/exotic_lists.ml b/testsuite/tests/tool-toplevel/exotic_lists.ml index bb09823bd9..a42ff0534b 100644 --- a/testsuite/tests/tool-toplevel/exotic_lists.ml +++ b/testsuite/tests/tool-toplevel/exotic_lists.ml @@ -1,5 +1,5 @@ (* TEST - * toplevel + toplevel; *) module L = struct diff --git a/testsuite/tests/tool-toplevel/install_printer.ml b/testsuite/tests/tool-toplevel/install_printer.ml index e14a0ced8f..1f5478fcfc 100644 --- a/testsuite/tests/tool-toplevel/install_printer.ml +++ b/testsuite/tests/tool-toplevel/install_printer.ml @@ -1,5 +1,5 @@ (* TEST - * toplevel + toplevel; *) (* simple printer *) diff --git a/testsuite/tests/tool-toplevel/known-bugs/broken_rec_in_show.ml b/testsuite/tests/tool-toplevel/known-bugs/broken_rec_in_show.ml index de8262bc0f..d496f06be4 100644 --- a/testsuite/tests/tool-toplevel/known-bugs/broken_rec_in_show.ml +++ b/testsuite/tests/tool-toplevel/known-bugs/broken_rec_in_show.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* This is a known-bug file for use of 'rec' by the '#show' command, diff --git a/testsuite/tests/tool-toplevel/mod_use.ml b/testsuite/tests/tool-toplevel/mod_use.ml index 4ea967e5c0..0b40a600e1 100644 --- a/testsuite/tests/tool-toplevel/mod_use.ml +++ b/testsuite/tests/tool-toplevel/mod_use.ml @@ -1,6 +1,6 @@ (* TEST - readonly_files = "mod.ml" - * expect + readonly_files = "mod.ml"; + expect; *) #mod_use "mod.ml" diff --git a/testsuite/tests/tool-toplevel/pr6468.ml b/testsuite/tests/tool-toplevel/pr6468.ml index 69680ccfdd..e4dc5c8f5c 100644 --- a/testsuite/tests/tool-toplevel/pr6468.ml +++ b/testsuite/tests/tool-toplevel/pr6468.ml @@ -1,5 +1,5 @@ (* TEST - * toplevel + toplevel; *) (* Make the test reproducible regardless of whether OCAMLRUNPARAM=b or not *) diff --git a/testsuite/tests/tool-toplevel/pr7060.ml b/testsuite/tests/tool-toplevel/pr7060.ml index e6ad740888..87e00e6010 100644 --- a/testsuite/tests/tool-toplevel/pr7060.ml +++ b/testsuite/tests/tool-toplevel/pr7060.ml @@ -1,5 +1,5 @@ (* TEST - * toplevel + toplevel; *) type t = A | B;; diff --git a/testsuite/tests/tool-toplevel/pr7751.ml b/testsuite/tests/tool-toplevel/pr7751.ml index 40ce9ffd44..d0c42e209c 100644 --- a/testsuite/tests/tool-toplevel/pr7751.ml +++ b/testsuite/tests/tool-toplevel/pr7751.ml @@ -1,6 +1,6 @@ (* TEST - include ocamlcommon - * toplevel + include ocamlcommon; + toplevel; *) Parse.expression (Lexing.from_string "1");; diff --git a/testsuite/tests/tool-toplevel/pr9701.ml b/testsuite/tests/tool-toplevel/pr9701.ml index 4dbbc2d614..daefafbff3 100644 --- a/testsuite/tests/tool-toplevel/pr9701.ml +++ b/testsuite/tests/tool-toplevel/pr9701.ml @@ -1,9 +1,9 @@ (* TEST -ocaml_script_as_argument = "true" -ocaml_exit_status = "2" -* setup-ocaml-build-env -** ocaml -*** check-ocaml-output + ocaml_script_as_argument = "true"; + ocaml_exit_status = "2"; + setup-ocaml-build-env; + ocaml; + check-ocaml-output; *) #1 "pr9701.ml" diff --git a/testsuite/tests/tool-toplevel/printval.ml b/testsuite/tests/tool-toplevel/printval.ml index 17c2744440..1305dad3fe 100644 --- a/testsuite/tests/tool-toplevel/printval.ml +++ b/testsuite/tests/tool-toplevel/printval.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* Test a success case *) diff --git a/testsuite/tests/tool-toplevel/redefinition_hints.ml b/testsuite/tests/tool-toplevel/redefinition_hints.ml index ee90af82db..2b691b7dd0 100644 --- a/testsuite/tests/tool-toplevel/redefinition_hints.ml +++ b/testsuite/tests/tool-toplevel/redefinition_hints.ml @@ -1,5 +1,5 @@ (* TEST - * toplevel + toplevel; *) (* This is a toplevel test to trigger toplevel specific hints *) diff --git a/testsuite/tests/tool-toplevel/show.ml b/testsuite/tests/tool-toplevel/show.ml index 28b59d9fdb..35ad009167 100644 --- a/testsuite/tests/tool-toplevel/show.ml +++ b/testsuite/tests/tool-toplevel/show.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* this is a set of tests to test the #show functionality diff --git a/testsuite/tests/tool-toplevel/show_short_paths.ml b/testsuite/tests/tool-toplevel/show_short_paths.ml index 000e775234..1051a1839f 100644 --- a/testsuite/tests/tool-toplevel/show_short_paths.ml +++ b/testsuite/tests/tool-toplevel/show_short_paths.ml @@ -1,6 +1,6 @@ (* TEST - flags = " -short-paths " - * expect + flags = " -short-paths "; + expect; *) (* This is currently just a regression test for the bug diff --git a/testsuite/tests/tool-toplevel/strings.ml b/testsuite/tests/tool-toplevel/strings.ml index baf2987153..982f2dd80d 100644 --- a/testsuite/tests/tool-toplevel/strings.ml +++ b/testsuite/tests/tool-toplevel/strings.ml @@ -1,5 +1,5 @@ (* TEST - * toplevel + toplevel; *) (* Test the printing of strings in the terminal *) diff --git a/testsuite/tests/tool-toplevel/topeval.ml b/testsuite/tests/tool-toplevel/topeval.ml index 802f04b5af..8be3c3232e 100644 --- a/testsuite/tests/tool-toplevel/topeval.ml +++ b/testsuite/tests/tool-toplevel/topeval.ml @@ -1,6 +1,9 @@ (* TEST - * toplevel - * toplevel.opt + { + toplevel; + }{ + toplevel.opt; + } *) (* Various test-cases ensuring that the native and bytecode toplevels produce diff --git a/testsuite/tests/tool-toplevel/tracing.ml b/testsuite/tests/tool-toplevel/tracing.ml index 8a1221f63a..f76e7026cf 100644 --- a/testsuite/tests/tool-toplevel/tracing.ml +++ b/testsuite/tests/tool-toplevel/tracing.ml @@ -1,5 +1,5 @@ (* TEST - * toplevel + toplevel; *) List.fold_left;; diff --git a/testsuite/tests/tool-toplevel/uncaught_exceptions.ml b/testsuite/tests/tool-toplevel/uncaught_exceptions.ml index 3544e1ddd0..634ef4a5b7 100644 --- a/testsuite/tests/tool-toplevel/uncaught_exceptions.ml +++ b/testsuite/tests/tool-toplevel/uncaught_exceptions.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* PR#8594 *) diff --git a/testsuite/tests/tool-toplevel/use_command.ml b/testsuite/tests/tool-toplevel/use_command.ml index 7bb9d8fa27..dbe28558a4 100644 --- a/testsuite/tests/tool-toplevel/use_command.ml +++ b/testsuite/tests/tool-toplevel/use_command.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* Test a success case *) diff --git a/testsuite/tests/translprim/array_spec.ml b/testsuite/tests/translprim/array_spec.ml index 6d0c1e49f8..70b65919ca 100644 --- a/testsuite/tests/translprim/array_spec.ml +++ b/testsuite/tests/translprim/array_spec.ml @@ -1,15 +1,16 @@ (* TEST - * setup-ocamlc.byte-build-env - ** ocamlc.byte - flags = "-dlambda -dno-unique-ids" - *** flat-float-array - **** check-ocamlc.byte-output - compiler_reference = - "${test_source_directory}/array_spec.compilers.flat.reference" - *** no-flat-float-array - **** check-ocamlc.byte-output - compiler_reference = - "${test_source_directory}/array_spec.compilers.no-flat.reference" + setup-ocamlc.byte-build-env; + flags = "-dlambda -dno-unique-ids"; + ocamlc.byte; + { + flat-float-array; + compiler_reference = "${test_source_directory}/array_spec.compilers.flat.reference"; + check-ocamlc.byte-output; + }{ + no-flat-float-array; + compiler_reference = "${test_source_directory}/array_spec.compilers.no-flat.reference"; + check-ocamlc.byte-output; + } *) external len : 'a array -> int = "%array_length" diff --git a/testsuite/tests/translprim/comparison_table.ml b/testsuite/tests/translprim/comparison_table.ml index 1a91430681..56ec388067 100644 --- a/testsuite/tests/translprim/comparison_table.ml +++ b/testsuite/tests/translprim/comparison_table.ml @@ -1,8 +1,8 @@ (* TEST - * setup-ocamlc.byte-build-env - ** ocamlc.byte - flags = "-dlambda -dno-unique-ids" - *** check-ocamlc.byte-output + setup-ocamlc.byte-build-env; + flags = "-dlambda -dno-unique-ids"; + ocamlc.byte; + check-ocamlc.byte-output; *) external cmp : 'a -> 'a -> int = "%compare";; diff --git a/testsuite/tests/translprim/locs.ml b/testsuite/tests/translprim/locs.ml index 79e4646875..b734f73505 100644 --- a/testsuite/tests/translprim/locs.ml +++ b/testsuite/tests/translprim/locs.ml @@ -1,4 +1,4 @@ -(* TEST *) +(* TEST_BELOW*) let print_loc loc = print_endline loc @@ -159,3 +159,6 @@ let () = (new klass)#meth (); inline_object (); bang () + +(* TEST +*) diff --git a/testsuite/tests/translprim/module_coercion.ml b/testsuite/tests/translprim/module_coercion.ml index a6d334c8ad..282e96e323 100644 --- a/testsuite/tests/translprim/module_coercion.ml +++ b/testsuite/tests/translprim/module_coercion.ml @@ -1,15 +1,16 @@ (* TEST - * setup-ocamlc.byte-build-env - ** ocamlc.byte - flags = "-dlambda -dno-unique-ids" - *** flat-float-array - **** check-ocamlc.byte-output - compiler_reference = - "${test_source_directory}/module_coercion.compilers.flat.reference" - *** no-flat-float-array - **** check-ocamlc.byte-output - compiler_reference = - "${test_source_directory}/module_coercion.compilers.no-flat.reference" + setup-ocamlc.byte-build-env; + flags = "-dlambda -dno-unique-ids"; + ocamlc.byte; + { + flat-float-array; + compiler_reference = "${test_source_directory}/module_coercion.compilers.flat.reference"; + check-ocamlc.byte-output; + }{ + no-flat-float-array; + compiler_reference = "${test_source_directory}/module_coercion.compilers.no-flat.reference"; + check-ocamlc.byte-output; + } *) module M = struct diff --git a/testsuite/tests/translprim/ref_spec.ml b/testsuite/tests/translprim/ref_spec.ml index 82cbd1eeef..de70cd5ec5 100644 --- a/testsuite/tests/translprim/ref_spec.ml +++ b/testsuite/tests/translprim/ref_spec.ml @@ -1,8 +1,8 @@ (* TEST - * setup-ocamlc.byte-build-env - ** ocamlc.byte - flags = "-dlambda -dno-unique-ids" - *** check-ocamlc.byte-output + setup-ocamlc.byte-build-env; + flags = "-dlambda -dno-unique-ids"; + ocamlc.byte; + check-ocamlc.byte-output; *) type 'a custom_rec = { x : unit; mutable y : 'a } diff --git a/testsuite/tests/typing-core-bugs/const_int_hint.ml b/testsuite/tests/typing-core-bugs/const_int_hint.ml index e802b02b45..1c82c0600f 100644 --- a/testsuite/tests/typing-core-bugs/const_int_hint.ml +++ b/testsuite/tests/typing-core-bugs/const_int_hint.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) let _ = Int32.(add 1 2l);; diff --git a/testsuite/tests/typing-core-bugs/missing_rec_hint.ml b/testsuite/tests/typing-core-bugs/missing_rec_hint.ml index f3e62e2b04..e62607a34c 100644 --- a/testsuite/tests/typing-core-bugs/missing_rec_hint.ml +++ b/testsuite/tests/typing-core-bugs/missing_rec_hint.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) let facto n = (* missing [rec] *) diff --git a/testsuite/tests/typing-core-bugs/repeated_did_you_mean.ml b/testsuite/tests/typing-core-bugs/repeated_did_you_mean.ml index 3c187fa4a2..d5ff406d01 100644 --- a/testsuite/tests/typing-core-bugs/repeated_did_you_mean.ml +++ b/testsuite/tests/typing-core-bugs/repeated_did_you_mean.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* MPR 7864 *) diff --git a/testsuite/tests/typing-core-bugs/type_expected_explanation.ml b/testsuite/tests/typing-core-bugs/type_expected_explanation.ml index fe9bc478ed..9616ffbc89 100644 --- a/testsuite/tests/typing-core-bugs/type_expected_explanation.ml +++ b/testsuite/tests/typing-core-bugs/type_expected_explanation.ml @@ -1,6 +1,6 @@ (* TEST - flags = "-strict-sequence" - * expect + flags = "-strict-sequence"; + expect; *) if 3 then ();; diff --git a/testsuite/tests/typing-core-bugs/unit_fun_hints.ml b/testsuite/tests/typing-core-bugs/unit_fun_hints.ml index 73b4ad22d6..1b9acece95 100644 --- a/testsuite/tests/typing-core-bugs/unit_fun_hints.ml +++ b/testsuite/tests/typing-core-bugs/unit_fun_hints.ml @@ -1,6 +1,6 @@ (* TEST - flags = "-strict-sequence" - * expect + flags = "-strict-sequence"; + expect; *) let g f = f () diff --git a/testsuite/tests/typing-deprecated/alerts.ml b/testsuite/tests/typing-deprecated/alerts.ml index edc07e4320..e9d7d89829 100644 --- a/testsuite/tests/typing-deprecated/alerts.ml +++ b/testsuite/tests/typing-deprecated/alerts.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) diff --git a/testsuite/tests/typing-deprecated/deprecated.ml b/testsuite/tests/typing-deprecated/deprecated.ml index c8c3707703..0ac02d610f 100644 --- a/testsuite/tests/typing-deprecated/deprecated.ml +++ b/testsuite/tests/typing-deprecated/deprecated.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) [@@@ocaml.warning "+3"];; diff --git a/testsuite/tests/typing-extension-constructor/test.ml b/testsuite/tests/typing-extension-constructor/test.ml index d18777c72d..b486694d92 100644 --- a/testsuite/tests/typing-extension-constructor/test.ml +++ b/testsuite/tests/typing-extension-constructor/test.ml @@ -1,5 +1,5 @@ (* TEST - * toplevel + toplevel; *) type t = ..;; diff --git a/testsuite/tests/typing-extensions/cast.ml b/testsuite/tests/typing-extensions/cast.ml index 7e155f5368..8bad32bb05 100644 --- a/testsuite/tests/typing-extensions/cast.ml +++ b/testsuite/tests/typing-extensions/cast.ml @@ -1,5 +1,5 @@ (* TEST - * toplevel + toplevel; *) (* Ignore OCAMLRUNPARAM=b to be reproducible *) diff --git a/testsuite/tests/typing-extensions/disambiguation.ml b/testsuite/tests/typing-extensions/disambiguation.ml index 4201763397..ba63fad7d2 100644 --- a/testsuite/tests/typing-extensions/disambiguation.ml +++ b/testsuite/tests/typing-extensions/disambiguation.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (** Test type-directed disambiguation and spellchecker hints *) diff --git a/testsuite/tests/typing-extensions/extensions.ml b/testsuite/tests/typing-extensions/extensions.ml index 060302105d..d9cacb9b22 100644 --- a/testsuite/tests/typing-extensions/extensions.ml +++ b/testsuite/tests/typing-extensions/extensions.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* Ignore OCAMLRUNPARAM=b to be reproducible *) diff --git a/testsuite/tests/typing-extensions/msg.ml b/testsuite/tests/typing-extensions/msg.ml index 07cdba656a..0a66f2a932 100644 --- a/testsuite/tests/typing-extensions/msg.ml +++ b/testsuite/tests/typing-extensions/msg.ml @@ -1,5 +1,5 @@ (* TEST - * toplevel + toplevel; *) (* Typed names *) diff --git a/testsuite/tests/typing-extensions/open_types.ml b/testsuite/tests/typing-extensions/open_types.ml index 16d4b03583..3ffbbd8c84 100644 --- a/testsuite/tests/typing-extensions/open_types.ml +++ b/testsuite/tests/typing-extensions/open_types.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type foo = .. diff --git a/testsuite/tests/typing-external/pr11392.ml b/testsuite/tests/typing-external/pr11392.ml index 91c8ea77eb..61cd5cada6 100644 --- a/testsuite/tests/typing-external/pr11392.ml +++ b/testsuite/tests/typing-external/pr11392.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type 'self nat = diff --git a/testsuite/tests/typing-fstclassmod/aliases.ml b/testsuite/tests/typing-fstclassmod/aliases.ml index f6043ed443..0ad18c98a0 100644 --- a/testsuite/tests/typing-fstclassmod/aliases.ml +++ b/testsuite/tests/typing-fstclassmod/aliases.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module M = struct end diff --git a/testsuite/tests/typing-fstclassmod/fstclassmod.ml b/testsuite/tests/typing-fstclassmod/fstclassmod.ml index 3330f957d8..2c31f30039 100644 --- a/testsuite/tests/typing-fstclassmod/fstclassmod.ml +++ b/testsuite/tests/typing-fstclassmod/fstclassmod.ml @@ -1,5 +1,5 @@ (* TEST - flags = "-w +A-70 -warn-error +A" + flags = "-w +A-70 -warn-error +A"; *) (* Example of algorithm parametrized with modules *) diff --git a/testsuite/tests/typing-fstclassmod/nondep_instance.ml b/testsuite/tests/typing-fstclassmod/nondep_instance.ml index 34f37b1c86..fec690651c 100644 --- a/testsuite/tests/typing-fstclassmod/nondep_instance.ml +++ b/testsuite/tests/typing-fstclassmod/nondep_instance.ml @@ -1,5 +1,6 @@ (* TEST - * expect *) + expect; +*) module type Vector_space = sig type t diff --git a/testsuite/tests/typing-fstclassmod/scope_escape.ml b/testsuite/tests/typing-fstclassmod/scope_escape.ml index 0ee735a674..c3e52e3d53 100644 --- a/testsuite/tests/typing-fstclassmod/scope_escape.ml +++ b/testsuite/tests/typing-fstclassmod/scope_escape.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* Typing for recursive modules checks scope escape *) diff --git a/testsuite/tests/typing-gadts/ambiguity.ml b/testsuite/tests/typing-gadts/ambiguity.ml index 36b651f13b..d6e9f86d75 100644 --- a/testsuite/tests/typing-gadts/ambiguity.ml +++ b/testsuite/tests/typing-gadts/ambiguity.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) [@@@warning "-8-11-12"] (* reduce the noise. *) diff --git a/testsuite/tests/typing-gadts/ambivalent_apply.ml b/testsuite/tests/typing-gadts/ambivalent_apply.ml index 5e44d26de5..2dc0cf72bd 100644 --- a/testsuite/tests/typing-gadts/ambivalent_apply.ml +++ b/testsuite/tests/typing-gadts/ambivalent_apply.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type (_,_) eq = Refl : ('a,'a) eq;; diff --git a/testsuite/tests/typing-gadts/didier.ml b/testsuite/tests/typing-gadts/didier.ml index 0e120e8503..75062f7608 100644 --- a/testsuite/tests/typing-gadts/didier.ml +++ b/testsuite/tests/typing-gadts/didier.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type 'a ty = diff --git a/testsuite/tests/typing-gadts/dynamic_frisch.ml b/testsuite/tests/typing-gadts/dynamic_frisch.ml index 8bef407420..56ad6d0576 100644 --- a/testsuite/tests/typing-gadts/dynamic_frisch.ml +++ b/testsuite/tests/typing-gadts/dynamic_frisch.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* Encoding generics using GADTs *) diff --git a/testsuite/tests/typing-gadts/gadthead.ml b/testsuite/tests/typing-gadts/gadthead.ml index 57a0f04d82..5e4cbfd5b0 100644 --- a/testsuite/tests/typing-gadts/gadthead.ml +++ b/testsuite/tests/typing-gadts/gadthead.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module M : sig diff --git a/testsuite/tests/typing-gadts/name_existentials.ml b/testsuite/tests/typing-gadts/name_existentials.ml index 91b2f5bb1d..71bc112d8d 100644 --- a/testsuite/tests/typing-gadts/name_existentials.ml +++ b/testsuite/tests/typing-gadts/name_existentials.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type _ ty = Int : int ty diff --git a/testsuite/tests/typing-gadts/nested_equations.ml b/testsuite/tests/typing-gadts/nested_equations.ml index b1719bfbd0..4a9173c039 100644 --- a/testsuite/tests/typing-gadts/nested_equations.ml +++ b/testsuite/tests/typing-gadts/nested_equations.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* Tests for nested equations (bind abstract types from other modules) *) diff --git a/testsuite/tests/typing-gadts/omega07.ml b/testsuite/tests/typing-gadts/omega07.ml index a8e6388035..01600502df 100644 --- a/testsuite/tests/typing-gadts/omega07.ml +++ b/testsuite/tests/typing-gadts/omega07.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* diff --git a/testsuite/tests/typing-gadts/or_patterns.ml b/testsuite/tests/typing-gadts/or_patterns.ml index e6606fb27f..623cd612b8 100644 --- a/testsuite/tests/typing-gadts/or_patterns.ml +++ b/testsuite/tests/typing-gadts/or_patterns.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type _ t = diff --git a/testsuite/tests/typing-gadts/packed-module-recasting.ml b/testsuite/tests/typing-gadts/packed-module-recasting.ml index 9cb8821673..73ac738c96 100644 --- a/testsuite/tests/typing-gadts/packed-module-recasting.ml +++ b/testsuite/tests/typing-gadts/packed-module-recasting.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type (_, _) eq = Refl : ('a, 'a) eq;; diff --git a/testsuite/tests/typing-gadts/pr10189.ml b/testsuite/tests/typing-gadts/pr10189.ml index 5df054fd10..65cb8183a3 100644 --- a/testsuite/tests/typing-gadts/pr10189.ml +++ b/testsuite/tests/typing-gadts/pr10189.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type i = <m : 'c. 'c -> 'c > diff --git a/testsuite/tests/typing-gadts/pr10271.ml b/testsuite/tests/typing-gadts/pr10271.ml index 37b6bdbc62..061e5568dc 100644 --- a/testsuite/tests/typing-gadts/pr10271.ml +++ b/testsuite/tests/typing-gadts/pr10271.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module M = struct diff --git a/testsuite/tests/typing-gadts/pr10348.ml b/testsuite/tests/typing-gadts/pr10348.ml index ba3e860770..23437dca3a 100644 --- a/testsuite/tests/typing-gadts/pr10348.ml +++ b/testsuite/tests/typing-gadts/pr10348.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) diff --git a/testsuite/tests/typing-gadts/pr10735.ml b/testsuite/tests/typing-gadts/pr10735.ml index 5405670b11..6202c3629e 100644 --- a/testsuite/tests/typing-gadts/pr10735.ml +++ b/testsuite/tests/typing-gadts/pr10735.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module X : sig diff --git a/testsuite/tests/typing-gadts/pr10907.ml b/testsuite/tests/typing-gadts/pr10907.ml index abd431f265..e0b9d4d557 100644 --- a/testsuite/tests/typing-gadts/pr10907.ml +++ b/testsuite/tests/typing-gadts/pr10907.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* from @dyzsr *) diff --git a/testsuite/tests/typing-gadts/pr11888.ml b/testsuite/tests/typing-gadts/pr11888.ml index b0ff6fcea0..b4d72ce91e 100644 --- a/testsuite/tests/typing-gadts/pr11888.ml +++ b/testsuite/tests/typing-gadts/pr11888.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type z diff --git a/testsuite/tests/typing-gadts/pr5332.ml b/testsuite/tests/typing-gadts/pr5332.ml index f81fff4955..851864a2f0 100644 --- a/testsuite/tests/typing-gadts/pr5332.ml +++ b/testsuite/tests/typing-gadts/pr5332.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type ('env, 'a) var = diff --git a/testsuite/tests/typing-gadts/pr5689.ml b/testsuite/tests/typing-gadts/pr5689.ml index f61d80af8e..87b2bef9e8 100644 --- a/testsuite/tests/typing-gadts/pr5689.ml +++ b/testsuite/tests/typing-gadts/pr5689.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type inkind = [ `Link | `Nonlink ] diff --git a/testsuite/tests/typing-gadts/pr5785.ml b/testsuite/tests/typing-gadts/pr5785.ml index 7817cb0422..102ba05f4b 100644 --- a/testsuite/tests/typing-gadts/pr5785.ml +++ b/testsuite/tests/typing-gadts/pr5785.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module Add (T : sig type two end) = diff --git a/testsuite/tests/typing-gadts/pr5848.ml b/testsuite/tests/typing-gadts/pr5848.ml index 1c908d781d..d76ecff296 100644 --- a/testsuite/tests/typing-gadts/pr5848.ml +++ b/testsuite/tests/typing-gadts/pr5848.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module B : sig diff --git a/testsuite/tests/typing-gadts/pr5906.ml b/testsuite/tests/typing-gadts/pr5906.ml index 86ebfd0e36..30d372733c 100644 --- a/testsuite/tests/typing-gadts/pr5906.ml +++ b/testsuite/tests/typing-gadts/pr5906.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type _ constant = diff --git a/testsuite/tests/typing-gadts/pr5948.ml b/testsuite/tests/typing-gadts/pr5948.ml index 9581adc3c6..9edbf430bd 100644 --- a/testsuite/tests/typing-gadts/pr5948.ml +++ b/testsuite/tests/typing-gadts/pr5948.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type tag = [`TagA | `TagB | `TagC];; diff --git a/testsuite/tests/typing-gadts/pr5981.ml b/testsuite/tests/typing-gadts/pr5981.ml index 3d01d36c9d..83502759c8 100644 --- a/testsuite/tests/typing-gadts/pr5981.ml +++ b/testsuite/tests/typing-gadts/pr5981.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module F(S : sig type 'a t end) = struct diff --git a/testsuite/tests/typing-gadts/pr5985.ml b/testsuite/tests/typing-gadts/pr5985.ml index d38d9eecca..d38e7e789d 100644 --- a/testsuite/tests/typing-gadts/pr5985.ml +++ b/testsuite/tests/typing-gadts/pr5985.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* Report from Jeremy Yallop *) diff --git a/testsuite/tests/typing-gadts/pr5989.ml b/testsuite/tests/typing-gadts/pr5989.ml index 27d086d3f0..a23ade0926 100644 --- a/testsuite/tests/typing-gadts/pr5989.ml +++ b/testsuite/tests/typing-gadts/pr5989.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type (_, _) t = diff --git a/testsuite/tests/typing-gadts/pr5997.ml b/testsuite/tests/typing-gadts/pr5997.ml index 0f9f85b469..907a394426 100644 --- a/testsuite/tests/typing-gadts/pr5997.ml +++ b/testsuite/tests/typing-gadts/pr5997.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type (_, _) comp = diff --git a/testsuite/tests/typing-gadts/pr6158.ml b/testsuite/tests/typing-gadts/pr6158.ml index 711304bb37..388cfbc4be 100644 --- a/testsuite/tests/typing-gadts/pr6158.ml +++ b/testsuite/tests/typing-gadts/pr6158.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type 'a t = T of 'a diff --git a/testsuite/tests/typing-gadts/pr6163.ml b/testsuite/tests/typing-gadts/pr6163.ml index cf06eaf58f..4ceecfe098 100644 --- a/testsuite/tests/typing-gadts/pr6163.ml +++ b/testsuite/tests/typing-gadts/pr6163.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type _ nat = diff --git a/testsuite/tests/typing-gadts/pr6174.ml b/testsuite/tests/typing-gadts/pr6174.ml index bf710891f8..d689f656c8 100644 --- a/testsuite/tests/typing-gadts/pr6174.ml +++ b/testsuite/tests/typing-gadts/pr6174.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type _ t = C : ((('a -> 'o) -> 'o) -> ('b -> 'o) -> 'o) t diff --git a/testsuite/tests/typing-gadts/pr6241.ml b/testsuite/tests/typing-gadts/pr6241.ml index bf1108aeac..c7975600df 100644 --- a/testsuite/tests/typing-gadts/pr6241.ml +++ b/testsuite/tests/typing-gadts/pr6241.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type (_, _) t = diff --git a/testsuite/tests/typing-gadts/pr6690.ml b/testsuite/tests/typing-gadts/pr6690.ml index ebf308d095..9e952be9fd 100644 --- a/testsuite/tests/typing-gadts/pr6690.ml +++ b/testsuite/tests/typing-gadts/pr6690.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type 'a visit_action diff --git a/testsuite/tests/typing-gadts/pr6817.ml b/testsuite/tests/typing-gadts/pr6817.ml index 6462143637..bc48ca8e29 100644 --- a/testsuite/tests/typing-gadts/pr6817.ml +++ b/testsuite/tests/typing-gadts/pr6817.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module A = struct diff --git a/testsuite/tests/typing-gadts/pr6934.ml b/testsuite/tests/typing-gadts/pr6934.ml index 76cb0563da..e2a692df34 100644 --- a/testsuite/tests/typing-gadts/pr6934.ml +++ b/testsuite/tests/typing-gadts/pr6934.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type nonrec t = A : t;; diff --git a/testsuite/tests/typing-gadts/pr6980.ml b/testsuite/tests/typing-gadts/pr6980.ml index 191443240e..d265467962 100644 --- a/testsuite/tests/typing-gadts/pr6980.ml +++ b/testsuite/tests/typing-gadts/pr6980.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type 'a t = [< `Foo | `Bar] as 'a;; diff --git a/testsuite/tests/typing-gadts/pr6993_bad.ml b/testsuite/tests/typing-gadts/pr6993_bad.ml index d3a74ce497..adfe73b74f 100644 --- a/testsuite/tests/typing-gadts/pr6993_bad.ml +++ b/testsuite/tests/typing-gadts/pr6993_bad.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type (_, _) eqp = Y : ('a, 'a) eqp | N : string -> ('a, 'b) eqp diff --git a/testsuite/tests/typing-gadts/pr7016.ml b/testsuite/tests/typing-gadts/pr7016.ml index 3da34245b8..8cc75878d4 100644 --- a/testsuite/tests/typing-gadts/pr7016.ml +++ b/testsuite/tests/typing-gadts/pr7016.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type (_, _) t = diff --git a/testsuite/tests/typing-gadts/pr7160.ml b/testsuite/tests/typing-gadts/pr7160.ml index 5a613052b8..b5584cefdb 100644 --- a/testsuite/tests/typing-gadts/pr7160.ml +++ b/testsuite/tests/typing-gadts/pr7160.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type _ t = diff --git a/testsuite/tests/typing-gadts/pr7214.ml b/testsuite/tests/typing-gadts/pr7214.ml index a14616d766..9923678685 100644 --- a/testsuite/tests/typing-gadts/pr7214.ml +++ b/testsuite/tests/typing-gadts/pr7214.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type _ t = I : int t;; diff --git a/testsuite/tests/typing-gadts/pr7222.ml b/testsuite/tests/typing-gadts/pr7222.ml index d0177e23c7..834d043e16 100644 --- a/testsuite/tests/typing-gadts/pr7222.ml +++ b/testsuite/tests/typing-gadts/pr7222.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type +'a n = private int diff --git a/testsuite/tests/typing-gadts/pr7230.ml b/testsuite/tests/typing-gadts/pr7230.ml index 1c29f5e4aa..40be65fb3b 100644 --- a/testsuite/tests/typing-gadts/pr7230.ml +++ b/testsuite/tests/typing-gadts/pr7230.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type _ t = T : int t;; diff --git a/testsuite/tests/typing-gadts/pr7234.ml b/testsuite/tests/typing-gadts/pr7234.ml index 614f0adce1..90d70026e7 100644 --- a/testsuite/tests/typing-gadts/pr7234.ml +++ b/testsuite/tests/typing-gadts/pr7234.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type (_, _) eq = Eq : ('a, 'a) eq | Neq : int -> ('a, 'b) eq;; diff --git a/testsuite/tests/typing-gadts/pr7260.ml b/testsuite/tests/typing-gadts/pr7260.ml index 2685e3b23b..d0a830d806 100644 --- a/testsuite/tests/typing-gadts/pr7260.ml +++ b/testsuite/tests/typing-gadts/pr7260.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type bar = < bar: unit > diff --git a/testsuite/tests/typing-gadts/pr7269.ml b/testsuite/tests/typing-gadts/pr7269.ml index 58da0d5ef5..def15bc141 100644 --- a/testsuite/tests/typing-gadts/pr7269.ml +++ b/testsuite/tests/typing-gadts/pr7269.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type s = [`A | `B] and sub = [`B];; diff --git a/testsuite/tests/typing-gadts/pr7298.ml b/testsuite/tests/typing-gadts/pr7298.ml index 931d96129b..06118652bb 100644 --- a/testsuite/tests/typing-gadts/pr7298.ml +++ b/testsuite/tests/typing-gadts/pr7298.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type t = T : t;; diff --git a/testsuite/tests/typing-gadts/pr7374.ml b/testsuite/tests/typing-gadts/pr7374.ml index 6e2d5e42ba..7aa139d9ce 100644 --- a/testsuite/tests/typing-gadts/pr7374.ml +++ b/testsuite/tests/typing-gadts/pr7374.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type ('a, 'b) eq = Refl : ('a, 'a) eq diff --git a/testsuite/tests/typing-gadts/pr7378.ml b/testsuite/tests/typing-gadts/pr7378.ml index fe771d8d0a..1499ac5960 100644 --- a/testsuite/tests/typing-gadts/pr7378.ml +++ b/testsuite/tests/typing-gadts/pr7378.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module X = struct diff --git a/testsuite/tests/typing-gadts/pr7381.ml b/testsuite/tests/typing-gadts/pr7381.ml index 7609cce77d..cdc9c88de5 100644 --- a/testsuite/tests/typing-gadts/pr7381.ml +++ b/testsuite/tests/typing-gadts/pr7381.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type (_,_) eql = Refl : ('a, 'a) eql;; diff --git a/testsuite/tests/typing-gadts/pr7390.ml b/testsuite/tests/typing-gadts/pr7390.ml index 7522209a38..5601519582 100644 --- a/testsuite/tests/typing-gadts/pr7390.ml +++ b/testsuite/tests/typing-gadts/pr7390.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type empty = Empty and filled = Filled diff --git a/testsuite/tests/typing-gadts/pr7391.ml b/testsuite/tests/typing-gadts/pr7391.ml index f16654c5a0..a4160b0b9c 100644 --- a/testsuite/tests/typing-gadts/pr7391.ml +++ b/testsuite/tests/typing-gadts/pr7391.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) class virtual child1 parent = diff --git a/testsuite/tests/typing-gadts/pr7397.ml b/testsuite/tests/typing-gadts/pr7397.ml index 8a85eaff8c..328f5a88c7 100644 --- a/testsuite/tests/typing-gadts/pr7397.ml +++ b/testsuite/tests/typing-gadts/pr7397.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type +'a t diff --git a/testsuite/tests/typing-gadts/pr7421.ml b/testsuite/tests/typing-gadts/pr7421.ml index 79acaceb7d..8bf4025a90 100644 --- a/testsuite/tests/typing-gadts/pr7421.ml +++ b/testsuite/tests/typing-gadts/pr7421.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type (_, _) eq = Refl : ('a, 'a) eq;; diff --git a/testsuite/tests/typing-gadts/pr7432.ml b/testsuite/tests/typing-gadts/pr7432.ml index abb2167be1..9e2903311a 100644 --- a/testsuite/tests/typing-gadts/pr7432.ml +++ b/testsuite/tests/typing-gadts/pr7432.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) #labels false;; diff --git a/testsuite/tests/typing-gadts/pr7520.ml b/testsuite/tests/typing-gadts/pr7520.ml index b4bfe2f4a8..1ee5446390 100644 --- a/testsuite/tests/typing-gadts/pr7520.ml +++ b/testsuite/tests/typing-gadts/pr7520.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type ('a, 'b) eq = Refl : ('a, 'a) eq diff --git a/testsuite/tests/typing-gadts/pr7618.ml b/testsuite/tests/typing-gadts/pr7618.ml index afff67b5e2..8fa12ef353 100644 --- a/testsuite/tests/typing-gadts/pr7618.ml +++ b/testsuite/tests/typing-gadts/pr7618.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type _ t = I : int t;; diff --git a/testsuite/tests/typing-gadts/pr7747.ml b/testsuite/tests/typing-gadts/pr7747.ml index 97b89061d0..ca5eeaa719 100644 --- a/testsuite/tests/typing-gadts/pr7747.ml +++ b/testsuite/tests/typing-gadts/pr7747.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type (_,_) eq = Refl : ('a,'a) eq diff --git a/testsuite/tests/typing-gadts/pr7902.ml b/testsuite/tests/typing-gadts/pr7902.ml index b88fc23e49..cee0ad0df3 100644 --- a/testsuite/tests/typing-gadts/pr7902.ml +++ b/testsuite/tests/typing-gadts/pr7902.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type ('a, 'b) segment = diff --git a/testsuite/tests/typing-gadts/pr9019.ml b/testsuite/tests/typing-gadts/pr9019.ml index 4f65c94398..47e408a2c6 100644 --- a/testsuite/tests/typing-gadts/pr9019.ml +++ b/testsuite/tests/typing-gadts/pr9019.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* #9012 by Thomas Refis *) diff --git a/testsuite/tests/typing-gadts/pr9759.ml b/testsuite/tests/typing-gadts/pr9759.ml index cf68cebbc5..7cdd9abd1b 100644 --- a/testsuite/tests/typing-gadts/pr9759.ml +++ b/testsuite/tests/typing-gadts/pr9759.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* #9759 by Thomas Refis *) diff --git a/testsuite/tests/typing-gadts/pr9799.ml b/testsuite/tests/typing-gadts/pr9799.ml index 5d083684bb..de7e598700 100644 --- a/testsuite/tests/typing-gadts/pr9799.ml +++ b/testsuite/tests/typing-gadts/pr9799.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type 'a t = diff --git a/testsuite/tests/typing-gadts/principality-and-gadts.ml b/testsuite/tests/typing-gadts/principality-and-gadts.ml index 4a1bbb52bc..83b8b2c8c7 100644 --- a/testsuite/tests/typing-gadts/principality-and-gadts.ml +++ b/testsuite/tests/typing-gadts/principality-and-gadts.ml @@ -1,5 +1,6 @@ (* TEST - * expect *) + expect; +*) module M = struct type t = A | B end;; [%%expect{| diff --git a/testsuite/tests/typing-gadts/return_type.ml b/testsuite/tests/typing-gadts/return_type.ml index ebd5340a69..7c2a16b7ab 100644 --- a/testsuite/tests/typing-gadts/return_type.ml +++ b/testsuite/tests/typing-gadts/return_type.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type i = int diff --git a/testsuite/tests/typing-gadts/term-conv.ml b/testsuite/tests/typing-gadts/term-conv.ml index 436100bac8..3c7f008055 100644 --- a/testsuite/tests/typing-gadts/term-conv.ml +++ b/testsuite/tests/typing-gadts/term-conv.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* HOAS to de Bruijn, by chak *) diff --git a/testsuite/tests/typing-gadts/test.ml b/testsuite/tests/typing-gadts/test.ml index aaa5be181f..b107d4e97c 100644 --- a/testsuite/tests/typing-gadts/test.ml +++ b/testsuite/tests/typing-gadts/test.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module Exp = diff --git a/testsuite/tests/typing-gadts/unexpected_existentials.ml b/testsuite/tests/typing-gadts/unexpected_existentials.ml index 5216dc5032..db79e922bb 100644 --- a/testsuite/tests/typing-gadts/unexpected_existentials.ml +++ b/testsuite/tests/typing-gadts/unexpected_existentials.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (** Test the error message for existential types apparearing in unexpected position *) diff --git a/testsuite/tests/typing-gadts/unify_mb.ml b/testsuite/tests/typing-gadts/unify_mb.ml index cea21717f9..7b0fafc0f0 100644 --- a/testsuite/tests/typing-gadts/unify_mb.ml +++ b/testsuite/tests/typing-gadts/unify_mb.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* First-Order Unification by Structural Recursion *) diff --git a/testsuite/tests/typing-gadts/variables_in_mcomp.ml b/testsuite/tests/typing-gadts/variables_in_mcomp.ml index 0a37045499..8e8985af4d 100644 --- a/testsuite/tests/typing-gadts/variables_in_mcomp.ml +++ b/testsuite/tests/typing-gadts/variables_in_mcomp.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module M = struct diff --git a/testsuite/tests/typing-gadts/yallop_bugs.ml b/testsuite/tests/typing-gadts/yallop_bugs.ml index 24181efc3b..bdd2a55d7c 100644 --- a/testsuite/tests/typing-gadts/yallop_bugs.ml +++ b/testsuite/tests/typing-gadts/yallop_bugs.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* Injectivity *) diff --git a/testsuite/tests/typing-immediate/immediate.ml b/testsuite/tests/typing-immediate/immediate.ml index 030f9bd79e..d1f09426f7 100644 --- a/testsuite/tests/typing-immediate/immediate.ml +++ b/testsuite/tests/typing-immediate/immediate.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module type S = sig type t [@@immediate] end;; diff --git a/testsuite/tests/typing-implicit_unpack/implicit_unpack.ml b/testsuite/tests/typing-implicit_unpack/implicit_unpack.ml index f967e0be9e..ae5fbbfad8 100644 --- a/testsuite/tests/typing-implicit_unpack/implicit_unpack.ml +++ b/testsuite/tests/typing-implicit_unpack/implicit_unpack.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* diff --git a/testsuite/tests/typing-kind/kind_mismatch.ml b/testsuite/tests/typing-kind/kind_mismatch.ml index 93f5e54d97..003645f7ed 100644 --- a/testsuite/tests/typing-kind/kind_mismatch.ml +++ b/testsuite/tests/typing-kind/kind_mismatch.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (** Error messages for kind mismatches. *) diff --git a/testsuite/tests/typing-misc-bugs/core_array_reduced_ok.ml b/testsuite/tests/typing-misc-bugs/core_array_reduced_ok.ml index 38b630185a..ca36163faa 100644 --- a/testsuite/tests/typing-misc-bugs/core_array_reduced_ok.ml +++ b/testsuite/tests/typing-misc-bugs/core_array_reduced_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) type sexp = A of string | L of sexp list diff --git a/testsuite/tests/typing-misc-bugs/gadt_declaration_check.ml b/testsuite/tests/typing-misc-bugs/gadt_declaration_check.ml index 432a502ff2..dd16d40c76 100644 --- a/testsuite/tests/typing-misc-bugs/gadt_declaration_check.ml +++ b/testsuite/tests/typing-misc-bugs/gadt_declaration_check.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type foo = Foo;; [%%expect{| diff --git a/testsuite/tests/typing-misc-bugs/pr6303_bad.ml b/testsuite/tests/typing-misc-bugs/pr6303_bad.ml index e2980e0f03..8a1706c1fc 100644 --- a/testsuite/tests/typing-misc-bugs/pr6303_bad.ml +++ b/testsuite/tests/typing-misc-bugs/pr6303_bad.ml @@ -1,11 +1,19 @@ -(* TEST -flags = " -w -a " -ocamlc_byte_exit_status = "2" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) type 'a foo = {x: 'a; y: int} let r = {{x = 0; y = 0} with x = 0} let r' : string foo = r + +(* TEST + flags = " -w -a "; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/typing-misc-bugs/pr6946_bad.ml b/testsuite/tests/typing-misc-bugs/pr6946_bad.ml index 5142becdf9..aae63d899c 100644 --- a/testsuite/tests/typing-misc-bugs/pr6946_bad.ml +++ b/testsuite/tests/typing-misc-bugs/pr6946_bad.ml @@ -1,10 +1,18 @@ -(* TEST -flags = " -w -a " -ocamlc_byte_exit_status = "2" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) external foo : int = "%ignore";; let _ = foo ();; + +(* TEST + flags = " -w -a "; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/typing-misc/apply_non_function.ml b/testsuite/tests/typing-misc/apply_non_function.ml index 8ac766a85f..7e768c6473 100644 --- a/testsuite/tests/typing-misc/apply_non_function.ml +++ b/testsuite/tests/typing-misc/apply_non_function.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) let print_lines = List.iter print_endline diff --git a/testsuite/tests/typing-misc/build_as_type.ml b/testsuite/tests/typing-misc/build_as_type.ml index 51aa4e2338..b1b8de7812 100644 --- a/testsuite/tests/typing-misc/build_as_type.ml +++ b/testsuite/tests/typing-misc/build_as_type.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) let f = function diff --git a/testsuite/tests/typing-misc/constraints.ml b/testsuite/tests/typing-misc/constraints.ml index ec6e052319..3550a0b7ec 100644 --- a/testsuite/tests/typing-misc/constraints.ml +++ b/testsuite/tests/typing-misc/constraints.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type 'a t = [`A of 'a t t] as 'a;; (* fails *) diff --git a/testsuite/tests/typing-misc/deep.ml b/testsuite/tests/typing-misc/deep.ml index 01ade06106..e8d207d55f 100644 --- a/testsuite/tests/typing-misc/deep.ml +++ b/testsuite/tests/typing-misc/deep.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module M : sig diff --git a/testsuite/tests/typing-misc/disambiguate_principality.ml b/testsuite/tests/typing-misc/disambiguate_principality.ml index d5529524fe..cec00b5c2a 100644 --- a/testsuite/tests/typing-misc/disambiguate_principality.ml +++ b/testsuite/tests/typing-misc/disambiguate_principality.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (*** Record ***) diff --git a/testsuite/tests/typing-misc/distant_errors.ml b/testsuite/tests/typing-misc/distant_errors.ml index f5f2ffd0fb..ef28cb8dfb 100644 --- a/testsuite/tests/typing-misc/distant_errors.ml +++ b/testsuite/tests/typing-misc/distant_errors.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (** The aim of this file is to keep track of programs that are "far" from being well-typed *) diff --git a/testsuite/tests/typing-misc/empty_variant.ml b/testsuite/tests/typing-misc/empty_variant.ml index 7aaa1afab4..6b2f7b8205 100644 --- a/testsuite/tests/typing-misc/empty_variant.ml +++ b/testsuite/tests/typing-misc/empty_variant.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* empty variant *) diff --git a/testsuite/tests/typing-misc/enrich_typedecl.ml b/testsuite/tests/typing-misc/enrich_typedecl.ml index ac699720d9..34e659cd91 100644 --- a/testsuite/tests/typing-misc/enrich_typedecl.ml +++ b/testsuite/tests/typing-misc/enrich_typedecl.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module rec A : sig diff --git a/testsuite/tests/typing-misc/exotic_unifications.ml b/testsuite/tests/typing-misc/exotic_unifications.ml index 2e3e69692f..56480999be 100644 --- a/testsuite/tests/typing-misc/exotic_unifications.ml +++ b/testsuite/tests/typing-misc/exotic_unifications.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) class virtual t = object method virtual x: float end diff --git a/testsuite/tests/typing-misc/external_arity.ml b/testsuite/tests/typing-misc/external_arity.ml index bad0fb1729..487fa83563 100644 --- a/testsuite/tests/typing-misc/external_arity.ml +++ b/testsuite/tests/typing-misc/external_arity.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) let f a b c = a + b + c diff --git a/testsuite/tests/typing-misc/filter_params.ml b/testsuite/tests/typing-misc/filter_params.ml index 879693680b..7035dd74e0 100644 --- a/testsuite/tests/typing-misc/filter_params.ml +++ b/testsuite/tests/typing-misc/filter_params.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type ('a, 'b) t constraint 'a = 'b diff --git a/testsuite/tests/typing-misc/gpr2277.ml b/testsuite/tests/typing-misc/gpr2277.ml index eabd3cc0ca..3d2b8b8d27 100644 --- a/testsuite/tests/typing-misc/gpr2277.ml +++ b/testsuite/tests/typing-misc/gpr2277.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) let f (type t) (x : t) = x diff --git a/testsuite/tests/typing-misc/includeclass_errors.ml b/testsuite/tests/typing-misc/includeclass_errors.ml index 033669e2a5..ddc5d16523 100644 --- a/testsuite/tests/typing-misc/includeclass_errors.ml +++ b/testsuite/tests/typing-misc/includeclass_errors.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) class type foo_t = diff --git a/testsuite/tests/typing-misc/injectivity.ml b/testsuite/tests/typing-misc/injectivity.ml index e6aedfa63d..42fc65d61a 100644 --- a/testsuite/tests/typing-misc/injectivity.ml +++ b/testsuite/tests/typing-misc/injectivity.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* Syntax *) diff --git a/testsuite/tests/typing-misc/inside_out.ml b/testsuite/tests/typing-misc/inside_out.ml index 077af37050..541586e4e6 100644 --- a/testsuite/tests/typing-misc/inside_out.ml +++ b/testsuite/tests/typing-misc/inside_out.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type ('a, 'b) eq = Refl : ('a, 'a) eq diff --git a/testsuite/tests/typing-misc/is_expansive.ml b/testsuite/tests/typing-misc/is_expansive.ml index 3bab4f9378..9a4d66da5e 100644 --- a/testsuite/tests/typing-misc/is_expansive.ml +++ b/testsuite/tests/typing-misc/is_expansive.ml @@ -1,5 +1,6 @@ (* TEST - * expect *) + expect; +*) match [] with x -> (fun x -> x);; [%%expect{| diff --git a/testsuite/tests/typing-misc/labels.ml b/testsuite/tests/typing-misc/labels.ml index 7cb3a7156f..862673752e 100644 --- a/testsuite/tests/typing-misc/labels.ml +++ b/testsuite/tests/typing-misc/labels.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* PR#5835 *) diff --git a/testsuite/tests/typing-misc/normalize_type.ml b/testsuite/tests/typing-misc/normalize_type.ml index 0b21b18303..6812764e5d 100644 --- a/testsuite/tests/typing-misc/normalize_type.ml +++ b/testsuite/tests/typing-misc/normalize_type.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* #8907 *) diff --git a/testsuite/tests/typing-misc/occur_check.ml b/testsuite/tests/typing-misc/occur_check.ml index 9d681c88a9..7a5d9c6d93 100644 --- a/testsuite/tests/typing-misc/occur_check.ml +++ b/testsuite/tests/typing-misc/occur_check.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* PR#5907 *) diff --git a/testsuite/tests/typing-misc/optbinders.ml b/testsuite/tests/typing-misc/optbinders.ml index ab1390675d..01af6bbf0b 100644 --- a/testsuite/tests/typing-misc/optbinders.ml +++ b/testsuite/tests/typing-misc/optbinders.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* Optional binders can be used in value declarations, diff --git a/testsuite/tests/typing-misc/pat_type_sharing.ml b/testsuite/tests/typing-misc/pat_type_sharing.ml index 1cbf69641b..4fd5dfa095 100644 --- a/testsuite/tests/typing-misc/pat_type_sharing.ml +++ b/testsuite/tests/typing-misc/pat_type_sharing.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type 'a r = { a : 'a; b : 'a; } type 'a ty = Int : int ty | Float : float ty;; diff --git a/testsuite/tests/typing-misc/pattern_open.ml b/testsuite/tests/typing-misc/pattern_open.ml index 16572b6eea..9fe25d5452 100644 --- a/testsuite/tests/typing-misc/pattern_open.ml +++ b/testsuite/tests/typing-misc/pattern_open.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) let pp fmt = Format.printf (fmt^^"@.") diff --git a/testsuite/tests/typing-misc/polyvars.ml b/testsuite/tests/typing-misc/polyvars.ml index 714bcf22c4..aaf281ec85 100644 --- a/testsuite/tests/typing-misc/polyvars.ml +++ b/testsuite/tests/typing-misc/polyvars.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type ab = [ `A | `B ];; diff --git a/testsuite/tests/typing-misc/pr6416.ml b/testsuite/tests/typing-misc/pr6416.ml index 0bfe20a11c..48edc2b2a3 100644 --- a/testsuite/tests/typing-misc/pr6416.ml +++ b/testsuite/tests/typing-misc/pr6416.ml @@ -1,6 +1,6 @@ (* TEST - flags="-no-alias-deps -w +40" - * expect + flags = "-no-alias-deps -w +40"; + expect; *) module M = struct type t = A diff --git a/testsuite/tests/typing-misc/pr6634.ml b/testsuite/tests/typing-misc/pr6634.ml index e96126cfcb..ffac718322 100644 --- a/testsuite/tests/typing-misc/pr6634.ml +++ b/testsuite/tests/typing-misc/pr6634.ml @@ -1,6 +1,6 @@ (* TEST - * expect - *) + expect; +*) type t = int module M : sig type t end with type t = [`T of t] = diff --git a/testsuite/tests/typing-misc/pr6939-flat-float-array.ml b/testsuite/tests/typing-misc/pr6939-flat-float-array.ml index 6c25346006..91ad731705 100644 --- a/testsuite/tests/typing-misc/pr6939-flat-float-array.ml +++ b/testsuite/tests/typing-misc/pr6939-flat-float-array.ml @@ -1,6 +1,6 @@ (* TEST - * flat-float-array - ** expect + flat-float-array; + expect; *) let rec x = [| x |]; 1.;; diff --git a/testsuite/tests/typing-misc/pr6939-no-flat-float-array.ml b/testsuite/tests/typing-misc/pr6939-no-flat-float-array.ml index c511bc625a..a3d139ac39 100644 --- a/testsuite/tests/typing-misc/pr6939-no-flat-float-array.ml +++ b/testsuite/tests/typing-misc/pr6939-no-flat-float-array.ml @@ -1,6 +1,6 @@ (* TEST - * no-flat-float-array - ** expect + no-flat-float-array; + expect; *) let rec x = [| x |]; 1.;; diff --git a/testsuite/tests/typing-misc/pr7103.ml b/testsuite/tests/typing-misc/pr7103.ml index 8156462392..ddb3b61ca7 100644 --- a/testsuite/tests/typing-misc/pr7103.ml +++ b/testsuite/tests/typing-misc/pr7103.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type 'a t diff --git a/testsuite/tests/typing-misc/pr7228.ml b/testsuite/tests/typing-misc/pr7228.ml index 1e98cca59d..480fa549af 100644 --- a/testsuite/tests/typing-misc/pr7228.ml +++ b/testsuite/tests/typing-misc/pr7228.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type t = A of {mutable x: int};; diff --git a/testsuite/tests/typing-misc/pr7668_bad.ml b/testsuite/tests/typing-misc/pr7668_bad.ml index e713488696..e9fe766d53 100644 --- a/testsuite/tests/typing-misc/pr7668_bad.ml +++ b/testsuite/tests/typing-misc/pr7668_bad.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) let partition_map f xs = diff --git a/testsuite/tests/typing-misc/pr7712.ml b/testsuite/tests/typing-misc/pr7712.ml index 09ffb4d297..b7ba586bef 100644 --- a/testsuite/tests/typing-misc/pr7712.ml +++ b/testsuite/tests/typing-misc/pr7712.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type 'a or_error = string diff --git a/testsuite/tests/typing-misc/pr7937.ml b/testsuite/tests/typing-misc/pr7937.ml index af812700fc..4c6ab29906 100644 --- a/testsuite/tests/typing-misc/pr7937.ml +++ b/testsuite/tests/typing-misc/pr7937.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type 'a r = [< `X of int & 'a ] as 'a diff --git a/testsuite/tests/typing-misc/pr8548.ml b/testsuite/tests/typing-misc/pr8548.ml index 7053ed6817..dd6cac13ef 100644 --- a/testsuite/tests/typing-misc/pr8548.ml +++ b/testsuite/tests/typing-misc/pr8548.ml @@ -1,5 +1,6 @@ (* TEST - * expect *) + expect; +*) module type Endpoint_intf = sig type t diff --git a/testsuite/tests/typing-misc/pr8548_split.ml b/testsuite/tests/typing-misc/pr8548_split.ml index 751dfa5603..5ba2cb09c7 100644 --- a/testsuite/tests/typing-misc/pr8548_split.ml +++ b/testsuite/tests/typing-misc/pr8548_split.ml @@ -1,20 +1,26 @@ (* TEST -readonly_files = "mapping.ml range_intf.ml ranged_intf.ml range.ml ranged.ml" -* setup-ocamlc.byte-build-env -** ocamlc.byte -flags = "-no-alias-deps -w -49 -o Pr8548__Mapping" -module = "mapping.ml" -** ocamlc.byte -flags = "-no-alias-deps -open Pr8548__Mapping -o pr8548__Range_intf.cmo" -module = "range_intf.ml" -*** ocamlc.byte -flags = "-no-alias-deps -open Pr8548__Mapping -o pr8548__Range.cmo" -module = "range.ml" -*** ocamlc.byte -flags = "-no-alias-deps -open Pr8548__Mapping -o pr8548__Ranged_intf.cmo" -module = "ranged_intf.ml" -**** ocamlc.byte -flags = "-no-alias-deps -open Pr8548__Mapping -o pr8548__Ranged.cmo" -module = "ranged.ml" -ocamlc_byte_exit_status = "0" + readonly_files = "mapping.ml range_intf.ml ranged_intf.ml range.ml ranged.ml"; + setup-ocamlc.byte-build-env; + { + flags = "-no-alias-deps -w -49 -o Pr8548__Mapping"; + module = "mapping.ml"; + ocamlc.byte; + }{ + flags = "-no-alias-deps -open Pr8548__Mapping -o pr8548__Range_intf.cmo"; + module = "range_intf.ml"; + ocamlc.byte; + { + flags = "-no-alias-deps -open Pr8548__Mapping -o pr8548__Range.cmo"; + module = "range.ml"; + ocamlc.byte; + }{ + flags = "-no-alias-deps -open Pr8548__Mapping -o pr8548__Ranged_intf.cmo"; + module = "ranged_intf.ml"; + ocamlc.byte; + flags = "-no-alias-deps -open Pr8548__Mapping -o pr8548__Ranged.cmo"; + module = "ranged.ml"; + ocamlc_byte_exit_status = "0"; + ocamlc.byte; + } + } *) diff --git a/testsuite/tests/typing-misc/printing.ml b/testsuite/tests/typing-misc/printing.ml index 1825ec439d..4a7113ff01 100644 --- a/testsuite/tests/typing-misc/printing.ml +++ b/testsuite/tests/typing-misc/printing.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* PR#7012 *) diff --git a/testsuite/tests/typing-misc/records.ml b/testsuite/tests/typing-misc/records.ml index 8bdf1988c5..bef54ec4ae 100644 --- a/testsuite/tests/typing-misc/records.ml +++ b/testsuite/tests/typing-misc/records.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* undefined labels *) diff --git a/testsuite/tests/typing-misc/scope_escape.ml b/testsuite/tests/typing-misc/scope_escape.ml index 94a47d236e..248cafc167 100644 --- a/testsuite/tests/typing-misc/scope_escape.ml +++ b/testsuite/tests/typing-misc/scope_escape.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) let x = ref [] diff --git a/testsuite/tests/typing-misc/typecore_empty_polyvariant_error.ml b/testsuite/tests/typing-misc/typecore_empty_polyvariant_error.ml index 9b4624d3e2..041f1f8eb0 100644 --- a/testsuite/tests/typing-misc/typecore_empty_polyvariant_error.ml +++ b/testsuite/tests/typing-misc/typecore_empty_polyvariant_error.ml @@ -1,12 +1,12 @@ (* TEST - readonly_files = "empty_ppx.ml" - * setup-ocamlc.byte-build-env - ** ocamlc.byte with ocamlcommon - all_modules="empty_ppx.ml" - program="ppx.exe" - *** toplevel - all_modules="${test_file}" - flags="-ppx '${ocamlrun} ${test_build_directory_prefix}/ocamlc.byte/ppx.exe'" + readonly_files = "empty_ppx.ml"; + setup-ocamlc.byte-build-env; + all_modules = "empty_ppx.ml"; + program = "ppx.exe"; + ocamlc.byte with ocamlcommon; + all_modules = "${test_file}"; + flags = "-ppx '${ocamlrun} ${test_build_directory_prefix}/ocamlc.byte/ppx.exe'"; + toplevel; *) type t = [%empty_polyvar];; diff --git a/testsuite/tests/typing-misc/typecore_errors.ml b/testsuite/tests/typing-misc/typecore_errors.ml index 9b00a4f692..432630f11a 100644 --- a/testsuite/tests/typing-misc/typecore_errors.ml +++ b/testsuite/tests/typing-misc/typecore_errors.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) diff --git a/testsuite/tests/typing-misc/typecore_nolabel_errors.ml b/testsuite/tests/typing-misc/typecore_nolabel_errors.ml index 04ecb52578..d0dcc9d1a6 100644 --- a/testsuite/tests/typing-misc/typecore_nolabel_errors.ml +++ b/testsuite/tests/typing-misc/typecore_nolabel_errors.ml @@ -1,6 +1,6 @@ (* TEST - flags="-nolabels" - * expect + flags = "-nolabels"; + expect; *) diff --git a/testsuite/tests/typing-misc/typetexp_errors.ml b/testsuite/tests/typing-misc/typetexp_errors.ml index 7dc03e90ac..4f71bd478b 100644 --- a/testsuite/tests/typing-misc/typetexp_errors.ml +++ b/testsuite/tests/typing-misc/typetexp_errors.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type ('a,'at,'any,'en) t = A of 'an diff --git a/testsuite/tests/typing-misc/unbound_type_variables.ml b/testsuite/tests/typing-misc/unbound_type_variables.ml index c00d036079..285d54ae0d 100644 --- a/testsuite/tests/typing-misc/unbound_type_variables.ml +++ b/testsuite/tests/typing-misc/unbound_type_variables.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type synonym = 'a -> 'a diff --git a/testsuite/tests/typing-misc/unique_names_in_unification.ml b/testsuite/tests/typing-misc/unique_names_in_unification.ml index 18a69f32bd..c1c1d546b6 100644 --- a/testsuite/tests/typing-misc/unique_names_in_unification.ml +++ b/testsuite/tests/typing-misc/unique_names_in_unification.ml @@ -1,6 +1,6 @@ (* TEST - * expect - *) + expect; +*) type t = A let x = A module M = struct diff --git a/testsuite/tests/typing-misc/variance.ml b/testsuite/tests/typing-misc/variance.ml index d0f754f716..d95282886f 100644 --- a/testsuite/tests/typing-misc/variance.ml +++ b/testsuite/tests/typing-misc/variance.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* #8698 *) diff --git a/testsuite/tests/typing-misc/variant.ml b/testsuite/tests/typing-misc/variant.ml index b7d5ae8aee..70052e22c3 100644 --- a/testsuite/tests/typing-misc/variant.ml +++ b/testsuite/tests/typing-misc/variant.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* PR#6394 *) diff --git a/testsuite/tests/typing-misc/wellfounded.ml b/testsuite/tests/typing-misc/wellfounded.ml index c8820f7ec8..3d0385167f 100644 --- a/testsuite/tests/typing-misc/wellfounded.ml +++ b/testsuite/tests/typing-misc/wellfounded.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* PR#6768 *) diff --git a/testsuite/tests/typing-misc/wrong_kind.ml b/testsuite/tests/typing-misc/wrong_kind.ml index 76d1a07688..8638b6a2d2 100644 --- a/testsuite/tests/typing-misc/wrong_kind.ml +++ b/testsuite/tests/typing-misc/wrong_kind.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module Constr = struct diff --git a/testsuite/tests/typing-missing-cmi-2/test.ml b/testsuite/tests/typing-missing-cmi-2/test.ml index 3321ba4622..72a30aee2e 100644 --- a/testsuite/tests/typing-missing-cmi-2/test.ml +++ b/testsuite/tests/typing-missing-cmi-2/test.ml @@ -1,15 +1,15 @@ (* TEST -readonly_files = "foo.mli bar.mli baz.ml" -* setup-ocamlc.byte-build-env -** ocamlc.byte -module = "foo.mli" -*** ocamlc.byte -module = "bar.mli" -**** script -script = "rm foo.cmi" -***** ocamlc.byte -flags = "-c -i" -module = "baz.ml" -ocamlc_byte_exit_status = "0" -****** check-ocamlc.byte-output + readonly_files = "foo.mli bar.mli baz.ml"; + setup-ocamlc.byte-build-env; + module = "foo.mli"; + ocamlc.byte; + module = "bar.mli"; + ocamlc.byte; + script = "rm foo.cmi"; + script; + flags = "-c -i"; + module = "baz.ml"; + ocamlc_byte_exit_status = "0"; + ocamlc.byte; + check-ocamlc.byte-output; *) diff --git a/testsuite/tests/typing-missing-cmi-3/user.ml b/testsuite/tests/typing-missing-cmi-3/user.ml index d34bff284a..497f97ace9 100644 --- a/testsuite/tests/typing-missing-cmi-3/user.ml +++ b/testsuite/tests/typing-missing-cmi-3/user.ml @@ -1,14 +1,13 @@ (* TEST - -readonly_files = "original.ml middle.ml" -* setup-ocamlc.byte-build-env -** ocamlc.byte -module = "original.ml" -*** ocamlc.byte -module = "middle.ml" -**** script -script = "rm -f original.cmi" -***** expect + readonly_files = "original.ml middle.ml"; + setup-ocamlc.byte-build-env; + module = "original.ml"; + ocamlc.byte; + module = "middle.ml"; + ocamlc.byte; + script = "rm -f original.cmi"; + script; + expect; *) diff --git a/testsuite/tests/typing-missing-cmi/test.ml b/testsuite/tests/typing-missing-cmi/test.ml index b946a8c1cb..a100351501 100644 --- a/testsuite/tests/typing-missing-cmi/test.ml +++ b/testsuite/tests/typing-missing-cmi/test.ml @@ -1,21 +1,21 @@ (* TEST -readonly_files = "a.ml b.ml c.ml main.ml main_ok.ml" -subdirectories = "subdir" -* setup-ocamlc.byte-build-env -** ocamlc.byte -module = "subdir/m.ml" -*** ocamlc.byte -flags = "-I subdir" -module = "a.ml" -**** ocamlc.byte -module = "b.ml" -***** ocamlc.byte -module = "c.ml" -****** ocamlc.byte -flags = "" -module = "main_ok.ml" -******* ocamlc.byte -module = "main.ml" -ocamlc_byte_exit_status = "2" -******** check-ocamlc.byte-output + readonly_files = "a.ml b.ml c.ml main.ml main_ok.ml"; + subdirectories = "subdir"; + setup-ocamlc.byte-build-env; + module = "subdir/m.ml"; + ocamlc.byte; + flags = "-I subdir"; + module = "a.ml"; + ocamlc.byte; + module = "b.ml"; + ocamlc.byte; + module = "c.ml"; + ocamlc.byte; + flags = ""; + module = "main_ok.ml"; + ocamlc.byte; + module = "main.ml"; + ocamlc_byte_exit_status = "2"; + ocamlc.byte; + check-ocamlc.byte-output; *) diff --git a/testsuite/tests/typing-modules-bugs/gatien_baron_20131019_ok.ml b/testsuite/tests/typing-modules-bugs/gatien_baron_20131019_ok.ml index fea9becac8..6b86ec4310 100644 --- a/testsuite/tests/typing-modules-bugs/gatien_baron_20131019_ok.ml +++ b/testsuite/tests/typing-modules-bugs/gatien_baron_20131019_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) module Std = struct module Hash = Hashtbl end;; diff --git a/testsuite/tests/typing-modules-bugs/pr10661_ok.ml b/testsuite/tests/typing-modules-bugs/pr10661_ok.ml index 1dfa42f434..300fe8f19c 100644 --- a/testsuite/tests/typing-modules-bugs/pr10661_ok.ml +++ b/testsuite/tests/typing-modules-bugs/pr10661_ok.ml @@ -1,7 +1,7 @@ (* TEST -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) module M = struct diff --git a/testsuite/tests/typing-modules-bugs/pr10693_bad.ml b/testsuite/tests/typing-modules-bugs/pr10693_bad.ml index 4e964c9e13..02122c9096 100644 --- a/testsuite/tests/typing-modules-bugs/pr10693_bad.ml +++ b/testsuite/tests/typing-modules-bugs/pr10693_bad.ml @@ -1,9 +1,9 @@ -(* TEST -flags = "-no-app-funct" -ocamlc_byte_exit_status = "2" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) module type Dep = sig type t val x : t end module String = struct type t = string let x = "Forty Two" end @@ -44,3 +44,11 @@ module N' = N.M(String) module N'' = N'.M(Int) let () = print_endline (Option.get N''.x) + +(* TEST + flags = "-no-app-funct"; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/typing-modules-bugs/pr5164_ok.ml b/testsuite/tests/typing-modules-bugs/pr5164_ok.ml index 9d8e571519..af34ebbcce 100644 --- a/testsuite/tests/typing-modules-bugs/pr5164_ok.ml +++ b/testsuite/tests/typing-modules-bugs/pr5164_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) module type INCLUDING = sig diff --git a/testsuite/tests/typing-modules-bugs/pr51_ok.ml b/testsuite/tests/typing-modules-bugs/pr51_ok.ml index 740d9bcca6..4e87369880 100644 --- a/testsuite/tests/typing-modules-bugs/pr51_ok.ml +++ b/testsuite/tests/typing-modules-bugs/pr51_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) module X=struct diff --git a/testsuite/tests/typing-modules-bugs/pr5663_ok.ml b/testsuite/tests/typing-modules-bugs/pr5663_ok.ml index 670869b8a5..1eebb3dd2c 100644 --- a/testsuite/tests/typing-modules-bugs/pr5663_ok.ml +++ b/testsuite/tests/typing-modules-bugs/pr5663_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) module F (M : sig diff --git a/testsuite/tests/typing-modules-bugs/pr5914_ok.ml b/testsuite/tests/typing-modules-bugs/pr5914_ok.ml index a027c0b090..766030b34c 100644 --- a/testsuite/tests/typing-modules-bugs/pr5914_ok.ml +++ b/testsuite/tests/typing-modules-bugs/pr5914_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) type 't a = [ `A ] diff --git a/testsuite/tests/typing-modules-bugs/pr6240_ok.ml b/testsuite/tests/typing-modules-bugs/pr6240_ok.ml index ce0ef4de5f..bed38dbc83 100644 --- a/testsuite/tests/typing-modules-bugs/pr6240_ok.ml +++ b/testsuite/tests/typing-modules-bugs/pr6240_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) module M : sig diff --git a/testsuite/tests/typing-modules-bugs/pr6293_bad.ml b/testsuite/tests/typing-modules-bugs/pr6293_bad.ml index db93799513..ba9997d11b 100644 --- a/testsuite/tests/typing-modules-bugs/pr6293_bad.ml +++ b/testsuite/tests/typing-modules-bugs/pr6293_bad.ml @@ -1,10 +1,18 @@ -(* TEST -flags = " -w -a " -ocamlc_byte_exit_status = "2" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) module type S = sig type t = { a : int; b : int; } end;; let f (module M : S with type t = int) = { M.a = 0 };; + +(* TEST + flags = " -w -a "; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/typing-modules-bugs/pr6427_bad.ml b/testsuite/tests/typing-modules-bugs/pr6427_bad.ml index 426c0369d5..85b4b1766c 100644 --- a/testsuite/tests/typing-modules-bugs/pr6427_bad.ml +++ b/testsuite/tests/typing-modules-bugs/pr6427_bad.ml @@ -1,9 +1,9 @@ -(* TEST -flags = " -w -a " -ocamlc_byte_exit_status = "2" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) let flag = ref false @@ -26,3 +26,11 @@ let () = flag := true module M2 = M(Float)(Int) let _ = [| M2.X.x; M1.X.x |] + +(* TEST + flags = " -w -a "; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/typing-modules-bugs/pr6485_ok.ml b/testsuite/tests/typing-modules-bugs/pr6485_ok.ml index cf9a946933..cf3b244a2a 100644 --- a/testsuite/tests/typing-modules-bugs/pr6485_ok.ml +++ b/testsuite/tests/typing-modules-bugs/pr6485_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) (** Check that rebinding module preserves private type aliases *) diff --git a/testsuite/tests/typing-modules-bugs/pr6513_ok.ml b/testsuite/tests/typing-modules-bugs/pr6513_ok.ml index 6148732604..a6caa16bd2 100644 --- a/testsuite/tests/typing-modules-bugs/pr6513_ok.ml +++ b/testsuite/tests/typing-modules-bugs/pr6513_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) module type PR6513 = sig diff --git a/testsuite/tests/typing-modules-bugs/pr6572_ok.ml b/testsuite/tests/typing-modules-bugs/pr6572_ok.ml index 28f33d3520..39a73814d2 100644 --- a/testsuite/tests/typing-modules-bugs/pr6572_ok.ml +++ b/testsuite/tests/typing-modules-bugs/pr6572_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) module type S = sig diff --git a/testsuite/tests/typing-modules-bugs/pr6651_ok.ml b/testsuite/tests/typing-modules-bugs/pr6651_ok.ml index db48d15f17..33c5db2387 100644 --- a/testsuite/tests/typing-modules-bugs/pr6651_ok.ml +++ b/testsuite/tests/typing-modules-bugs/pr6651_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) module type S = sig diff --git a/testsuite/tests/typing-modules-bugs/pr6752_bad.ml b/testsuite/tests/typing-modules-bugs/pr6752_bad.ml index 42d39e6afd..3e087e88ff 100644 --- a/testsuite/tests/typing-modules-bugs/pr6752_bad.ml +++ b/testsuite/tests/typing-modules-bugs/pr6752_bad.ml @@ -1,9 +1,9 @@ -(* TEST -flags = " -w -a " -ocamlc_byte_exit_status = "2" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) (* Sorry, we have to disable this as this requires accepting @@ -52,3 +52,11 @@ module M1 = let () = Common.add (Reload "config.file") let () = Common.add (Alert "Initialisation done") end + +(* TEST + flags = " -w -a "; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/typing-modules-bugs/pr6752_ok.ml b/testsuite/tests/typing-modules-bugs/pr6752_ok.ml index 2d5ac02ad3..fe1b3ce37c 100644 --- a/testsuite/tests/typing-modules-bugs/pr6752_ok.ml +++ b/testsuite/tests/typing-modules-bugs/pr6752_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) (* Adding a type annotation is sufficient to make typing go through *) diff --git a/testsuite/tests/typing-modules-bugs/pr6899_first_bad.ml b/testsuite/tests/typing-modules-bugs/pr6899_first_bad.ml index d7c1f71a33..4a265df2c5 100644 --- a/testsuite/tests/typing-modules-bugs/pr6899_first_bad.ml +++ b/testsuite/tests/typing-modules-bugs/pr6899_first_bad.ml @@ -1,11 +1,19 @@ -(* TEST -flags = " -w -a " -ocamlc_byte_exit_status = "2" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) let should_reject = let table = Hashtbl.create 1 in fun x y -> Hashtbl.add table x y + +(* TEST + flags = " -w -a "; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/typing-modules-bugs/pr6899_ok.ml b/testsuite/tests/typing-modules-bugs/pr6899_ok.ml index 95d0860c0b..85a8ab55a8 100644 --- a/testsuite/tests/typing-modules-bugs/pr6899_ok.ml +++ b/testsuite/tests/typing-modules-bugs/pr6899_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) type 'a t = 'a option diff --git a/testsuite/tests/typing-modules-bugs/pr6899_second_bad.ml b/testsuite/tests/typing-modules-bugs/pr6899_second_bad.ml index 42d8bdde48..3600362368 100644 --- a/testsuite/tests/typing-modules-bugs/pr6899_second_bad.ml +++ b/testsuite/tests/typing-modules-bugs/pr6899_second_bad.ml @@ -1,9 +1,9 @@ -(* TEST -flags = " -w -a " -ocamlc_byte_exit_status = "2" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) include struct @@ -11,3 +11,11 @@ include struct let wrap f `Test = f let bar = wrap () end + +(* TEST + flags = " -w -a "; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/typing-modules-bugs/pr6944_ok.ml b/testsuite/tests/typing-modules-bugs/pr6944_ok.ml index 9ff8d3564e..a54f65dbeb 100644 --- a/testsuite/tests/typing-modules-bugs/pr6944_ok.ml +++ b/testsuite/tests/typing-modules-bugs/pr6944_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) let f () = diff --git a/testsuite/tests/typing-modules-bugs/pr6954_ok.ml b/testsuite/tests/typing-modules-bugs/pr6954_ok.ml index 2970e4f340..b6963da967 100644 --- a/testsuite/tests/typing-modules-bugs/pr6954_ok.ml +++ b/testsuite/tests/typing-modules-bugs/pr6954_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) module X = struct module Y = struct module type S = sig type t end end end diff --git a/testsuite/tests/typing-modules-bugs/pr6981_ok.ml b/testsuite/tests/typing-modules-bugs/pr6981_ok.ml index 449e9dc754..2f7f54bd22 100644 --- a/testsuite/tests/typing-modules-bugs/pr6981_ok.ml +++ b/testsuite/tests/typing-modules-bugs/pr6981_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) module type S = diff --git a/testsuite/tests/typing-modules-bugs/pr6982_ok.ml b/testsuite/tests/typing-modules-bugs/pr6982_ok.ml index 47b65abba8..81261287b0 100644 --- a/testsuite/tests/typing-modules-bugs/pr6982_ok.ml +++ b/testsuite/tests/typing-modules-bugs/pr6982_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) module A = struct diff --git a/testsuite/tests/typing-modules-bugs/pr6985_extended.ml b/testsuite/tests/typing-modules-bugs/pr6985_extended.ml index 01faa3fe04..26c1ed1678 100644 --- a/testsuite/tests/typing-modules-bugs/pr6985_extended.ml +++ b/testsuite/tests/typing-modules-bugs/pr6985_extended.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) diff --git a/testsuite/tests/typing-modules-bugs/pr6985_ok.ml b/testsuite/tests/typing-modules-bugs/pr6985_ok.ml index 043502dae9..8852a8fa98 100644 --- a/testsuite/tests/typing-modules-bugs/pr6985_ok.ml +++ b/testsuite/tests/typing-modules-bugs/pr6985_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) module Foo diff --git a/testsuite/tests/typing-modules-bugs/pr6992_bad.ml b/testsuite/tests/typing-modules-bugs/pr6992_bad.ml index 18733c706b..48f1f592af 100644 --- a/testsuite/tests/typing-modules-bugs/pr6992_bad.ml +++ b/testsuite/tests/typing-modules-bugs/pr6992_bad.ml @@ -1,9 +1,9 @@ -(* TEST -flags = " -w -a " -ocamlc_byte_exit_status = "2" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) (* PR#6992, reported by Stephen Dolan *) @@ -21,3 +21,11 @@ module FixId = Fix (struct type 'a f = 'a end) let bad : (int, string) eq = FixId.uniq Eq Eq let _ = Printf.printf "Oh dear: %s" (cast bad 42) *) + +(* TEST + flags = " -w -a "; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/typing-modules-bugs/pr7036_ok.ml b/testsuite/tests/typing-modules-bugs/pr7036_ok.ml index 305d2425a7..711e9af2d5 100644 --- a/testsuite/tests/typing-modules-bugs/pr7036_ok.ml +++ b/testsuite/tests/typing-modules-bugs/pr7036_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) module M = struct diff --git a/testsuite/tests/typing-modules-bugs/pr7082_ok.ml b/testsuite/tests/typing-modules-bugs/pr7082_ok.ml index 849427d44b..59f714acfa 100644 --- a/testsuite/tests/typing-modules-bugs/pr7082_ok.ml +++ b/testsuite/tests/typing-modules-bugs/pr7082_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) module type FOO = sig type t end diff --git a/testsuite/tests/typing-modules-bugs/pr7112_bad.ml b/testsuite/tests/typing-modules-bugs/pr7112_bad.ml index ffc634901f..20738024e1 100644 --- a/testsuite/tests/typing-modules-bugs/pr7112_bad.ml +++ b/testsuite/tests/typing-modules-bugs/pr7112_bad.ml @@ -1,9 +1,9 @@ -(* TEST -flags = " -w -a " -ocamlc_byte_exit_status = "2" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) module A = struct module type S module S = struct end end @@ -11,3 +11,11 @@ module F (_ : sig end) = struct module type S module S = A.S end module M = struct end module N = M module G (X : F(N).S) : A.S = X + +(* TEST + flags = " -w -a "; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/typing-modules-bugs/pr7112_ok.ml b/testsuite/tests/typing-modules-bugs/pr7112_ok.ml index 666c604c56..1ce72502e4 100644 --- a/testsuite/tests/typing-modules-bugs/pr7112_ok.ml +++ b/testsuite/tests/typing-modules-bugs/pr7112_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) module F (_ : sig end) = struct module type S end diff --git a/testsuite/tests/typing-modules-bugs/pr7152_ok.ml b/testsuite/tests/typing-modules-bugs/pr7152_ok.ml index eada285f76..29543b1c39 100644 --- a/testsuite/tests/typing-modules-bugs/pr7152_ok.ml +++ b/testsuite/tests/typing-modules-bugs/pr7152_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) module M : sig diff --git a/testsuite/tests/typing-modules-bugs/pr7182_ok.ml b/testsuite/tests/typing-modules-bugs/pr7182_ok.ml index 801348f9f6..8e9bfd9c12 100644 --- a/testsuite/tests/typing-modules-bugs/pr7182_ok.ml +++ b/testsuite/tests/typing-modules-bugs/pr7182_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) module rec M diff --git a/testsuite/tests/typing-modules-bugs/pr7305_principal.ml b/testsuite/tests/typing-modules-bugs/pr7305_principal.ml index 3371e37886..7d31856a72 100644 --- a/testsuite/tests/typing-modules-bugs/pr7305_principal.ml +++ b/testsuite/tests/typing-modules-bugs/pr7305_principal.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -principal -w +18+19 -warn-error +A " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -principal -w +18+19 -warn-error +A "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) type c1 = < c1: c1 > diff --git a/testsuite/tests/typing-modules-bugs/pr7321_ok.ml b/testsuite/tests/typing-modules-bugs/pr7321_ok.ml index 9d21784738..b0ad633dbe 100644 --- a/testsuite/tests/typing-modules-bugs/pr7321_ok.ml +++ b/testsuite/tests/typing-modules-bugs/pr7321_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) module type S = sig type 'a t end diff --git a/testsuite/tests/typing-modules-bugs/pr7414_2_bad.ml b/testsuite/tests/typing-modules-bugs/pr7414_2_bad.ml index 1926ae4425..1d503a059c 100644 --- a/testsuite/tests/typing-modules-bugs/pr7414_2_bad.ml +++ b/testsuite/tests/typing-modules-bugs/pr7414_2_bad.ml @@ -1,9 +1,9 @@ -(* TEST -flags = " -w -a " -ocamlc_byte_exit_status = "2" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) module type T = sig @@ -48,3 +48,11 @@ let () = let () = (!M'.r) := [M'.Choice.x] in let module N' = (N : S) in List.iter (fun x -> print_string (N'.Choice.show x)) !(!N'.r) + +(* TEST + flags = " -w -a "; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/typing-modules-bugs/pr7414_bad.ml b/testsuite/tests/typing-modules-bugs/pr7414_bad.ml index 7bc294599d..25b1b80d59 100644 --- a/testsuite/tests/typing-modules-bugs/pr7414_bad.ml +++ b/testsuite/tests/typing-modules-bugs/pr7414_bad.ml @@ -1,9 +1,9 @@ -(* TEST -flags = " -w -a " -ocamlc_byte_exit_status = "2" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) module type T = sig @@ -61,3 +61,11 @@ module N' = (N : S) let () = List.iter (fun x -> print_string (N'.Choice.show x)) !(!N'.r) *) + +(* TEST + flags = " -w -a "; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/typing-modules-bugs/pr7519_ok.ml b/testsuite/tests/typing-modules-bugs/pr7519_ok.ml index c6278ce392..4b1cd79747 100644 --- a/testsuite/tests/typing-modules-bugs/pr7519_ok.ml +++ b/testsuite/tests/typing-modules-bugs/pr7519_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) module Gen_spec = struct type 't extra = unit end diff --git a/testsuite/tests/typing-modules-bugs/pr7601_ok.ml b/testsuite/tests/typing-modules-bugs/pr7601_ok.ml index 8000392014..b9ed83c7cf 100644 --- a/testsuite/tests/typing-modules-bugs/pr7601_ok.ml +++ b/testsuite/tests/typing-modules-bugs/pr7601_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) (**************************************************************************) diff --git a/testsuite/tests/typing-modules-bugs/pr7601a_ok.ml b/testsuite/tests/typing-modules-bugs/pr7601a_ok.ml index ce2b8bb71b..4e062e0b45 100644 --- a/testsuite/tests/typing-modules-bugs/pr7601a_ok.ml +++ b/testsuite/tests/typing-modules-bugs/pr7601a_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) module type Param1 = sig diff --git a/testsuite/tests/typing-modules-bugs/pr9695_bad.ml b/testsuite/tests/typing-modules-bugs/pr9695_bad.ml index 86ea3f8cdf..b0e8803b35 100644 --- a/testsuite/tests/typing-modules-bugs/pr9695_bad.ml +++ b/testsuite/tests/typing-modules-bugs/pr9695_bad.ml @@ -1,10 +1,18 @@ -(* TEST -flags = " -w -a -no-alias-deps" -ocamlc_byte_exit_status = "2" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) module A = MissingModule let () = let open A in x + +(* TEST + flags = " -w -a -no-alias-deps"; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/typing-modules/Test.ml b/testsuite/tests/typing-modules/Test.ml index f87fa521d1..17afb6483f 100644 --- a/testsuite/tests/typing-modules/Test.ml +++ b/testsuite/tests/typing-modules/Test.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* with module *) diff --git a/testsuite/tests/typing-modules/aliases.ml b/testsuite/tests/typing-modules/aliases.ml index b9ed5c6e8c..a242d844bd 100644 --- a/testsuite/tests/typing-modules/aliases.ml +++ b/testsuite/tests/typing-modules/aliases.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module C = Char;; diff --git a/testsuite/tests/typing-modules/anonymous.ml b/testsuite/tests/typing-modules/anonymous.ml index 7d006eddd9..367eb38184 100644 --- a/testsuite/tests/typing-modules/anonymous.ml +++ b/testsuite/tests/typing-modules/anonymous.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module _ = struct end;; diff --git a/testsuite/tests/typing-modules/applicative_functor_type.ml b/testsuite/tests/typing-modules/applicative_functor_type.ml index 01c6127490..172a0dd30a 100644 --- a/testsuite/tests/typing-modules/applicative_functor_type.ml +++ b/testsuite/tests/typing-modules/applicative_functor_type.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type t = Set.Make(String).t diff --git a/testsuite/tests/typing-modules/extension_constructors_errors_test.ml b/testsuite/tests/typing-modules/extension_constructors_errors_test.ml index b37f9d17a2..b273c9d0e8 100644 --- a/testsuite/tests/typing-modules/extension_constructors_errors_test.ml +++ b/testsuite/tests/typing-modules/extension_constructors_errors_test.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type t = ..;; diff --git a/testsuite/tests/typing-modules/firstclass.ml b/testsuite/tests/typing-modules/firstclass.ml index a79d01d93f..6a442b5270 100644 --- a/testsuite/tests/typing-modules/firstclass.ml +++ b/testsuite/tests/typing-modules/firstclass.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module type S = sig type u type t end;; diff --git a/testsuite/tests/typing-modules/functors.ml b/testsuite/tests/typing-modules/functors.ml index f51e2081a8..9aa275bfcd 100644 --- a/testsuite/tests/typing-modules/functors.ml +++ b/testsuite/tests/typing-modules/functors.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) diff --git a/testsuite/tests/typing-modules/generative.ml b/testsuite/tests/typing-modules/generative.ml index a3710a4ce0..ce168e3a29 100644 --- a/testsuite/tests/typing-modules/generative.ml +++ b/testsuite/tests/typing-modules/generative.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* Using generative functors *) diff --git a/testsuite/tests/typing-modules/illegal_permutation.ml b/testsuite/tests/typing-modules/illegal_permutation.ml index fabe8548c5..820dfb9483 100644 --- a/testsuite/tests/typing-modules/illegal_permutation.ml +++ b/testsuite/tests/typing-modules/illegal_permutation.ml @@ -1,5 +1,5 @@ (* TEST -* expect + expect; *) class type ct = object end module type s = sig type a val one:int type b class two:ct type c type exn+=Three type d end diff --git a/testsuite/tests/typing-modules/inclusion_errors.ml b/testsuite/tests/typing-modules/inclusion_errors.ml index fa5d3d5358..fe5243e258 100644 --- a/testsuite/tests/typing-modules/inclusion_errors.ml +++ b/testsuite/tests/typing-modules/inclusion_errors.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (********************************** Equality **********************************) diff --git a/testsuite/tests/typing-modules/inclusion_errors_elision.ml b/testsuite/tests/typing-modules/inclusion_errors_elision.ml index 3dbd0e67ff..1ce88ba424 100644 --- a/testsuite/tests/typing-modules/inclusion_errors_elision.ml +++ b/testsuite/tests/typing-modules/inclusion_errors_elision.ml @@ -1,7 +1,7 @@ (* TEST - flags ="-keep-original-error-size" - * expect - *) + flags = "-keep-original-error-size"; + expect; +*) module A = struct diff --git a/testsuite/tests/typing-modules/merge_constraint.ml b/testsuite/tests/typing-modules/merge_constraint.ml index d5c439e941..54fb887ac4 100644 --- a/testsuite/tests/typing-modules/merge_constraint.ml +++ b/testsuite/tests/typing-modules/merge_constraint.ml @@ -1,6 +1,7 @@ (* TEST - ocamlrunparam = "l=1000000" - * expect *) + ocamlrunparam = "l=1000000"; + expect; +*) (* #9623 *) diff --git a/testsuite/tests/typing-modules/module_type_substitution.ml b/testsuite/tests/typing-modules/module_type_substitution.ml index 09f16ce7be..3aa341ab37 100644 --- a/testsuite/tests/typing-modules/module_type_substitution.ml +++ b/testsuite/tests/typing-modules/module_type_substitution.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (** Basic *) diff --git a/testsuite/tests/typing-modules/nondep.ml b/testsuite/tests/typing-modules/nondep.ml index 36e541127f..e74731dd4e 100644 --- a/testsuite/tests/typing-modules/nondep.ml +++ b/testsuite/tests/typing-modules/nondep.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module F(X : sig type t end) = struct diff --git a/testsuite/tests/typing-modules/nondep_private_abbrev.ml b/testsuite/tests/typing-modules/nondep_private_abbrev.ml index a0daa1fb95..282b04e130 100644 --- a/testsuite/tests/typing-modules/nondep_private_abbrev.ml +++ b/testsuite/tests/typing-modules/nondep_private_abbrev.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module F(_ : sig end) : sig diff --git a/testsuite/tests/typing-modules/nongen.ml b/testsuite/tests/typing-modules/nongen.ml index 8fbea248b5..9aca5a1f88 100644 --- a/testsuite/tests/typing-modules/nongen.ml +++ b/testsuite/tests/typing-modules/nongen.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module X = struct diff --git a/testsuite/tests/typing-modules/normalize_path.ml b/testsuite/tests/typing-modules/normalize_path.ml index 44f45ef49e..fcca202ee7 100644 --- a/testsuite/tests/typing-modules/normalize_path.ml +++ b/testsuite/tests/typing-modules/normalize_path.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module X = struct diff --git a/testsuite/tests/typing-modules/packed_module_levels.ml b/testsuite/tests/typing-modules/packed_module_levels.ml index a4883d00de..a111d2fd4c 100644 --- a/testsuite/tests/typing-modules/packed_module_levels.ml +++ b/testsuite/tests/typing-modules/packed_module_levels.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type (_, _) equ = Refl : ('q, 'q) equ diff --git a/testsuite/tests/typing-modules/pr10298.ml b/testsuite/tests/typing-modules/pr10298.ml index 58a9509cd7..d1f8f9eafe 100644 --- a/testsuite/tests/typing-modules/pr10298.ml +++ b/testsuite/tests/typing-modules/pr10298.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module type S = sig type t end diff --git a/testsuite/tests/typing-modules/pr10399.ml b/testsuite/tests/typing-modules/pr10399.ml index cce02f41a2..89e25af0de 100644 --- a/testsuite/tests/typing-modules/pr10399.ml +++ b/testsuite/tests/typing-modules/pr10399.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* From jctis: <https://github.com/ocaml/ocaml/issues/10399> *) diff --git a/testsuite/tests/typing-modules/pr5911.ml b/testsuite/tests/typing-modules/pr5911.ml index 1c08b37af2..44f141e583 100644 --- a/testsuite/tests/typing-modules/pr5911.ml +++ b/testsuite/tests/typing-modules/pr5911.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module type S = sig diff --git a/testsuite/tests/typing-modules/pr6394.ml b/testsuite/tests/typing-modules/pr6394.ml index d785fb5065..0546f86414 100644 --- a/testsuite/tests/typing-modules/pr6394.ml +++ b/testsuite/tests/typing-modules/pr6394.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) [@@@ ocaml.warning "+4"] diff --git a/testsuite/tests/typing-modules/pr6633.ml b/testsuite/tests/typing-modules/pr6633.ml index 084cc63cd3..f8b791961e 100644 --- a/testsuite/tests/typing-modules/pr6633.ml +++ b/testsuite/tests/typing-modules/pr6633.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) diff --git a/testsuite/tests/typing-modules/pr7207.ml b/testsuite/tests/typing-modules/pr7207.ml index a061a34d67..aa9b7b5e92 100644 --- a/testsuite/tests/typing-modules/pr7207.ml +++ b/testsuite/tests/typing-modules/pr7207.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module F (X : sig end) = struct type t = int end;; diff --git a/testsuite/tests/typing-modules/pr7348.ml b/testsuite/tests/typing-modules/pr7348.ml index dc0cf4050d..4cd0671e3e 100644 --- a/testsuite/tests/typing-modules/pr7348.ml +++ b/testsuite/tests/typing-modules/pr7348.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module F (X : sig type t = private < foo:int; ..> val x : t end) = struct diff --git a/testsuite/tests/typing-modules/pr7726.ml b/testsuite/tests/typing-modules/pr7726.ml index 2fdd500dbd..6ea1b7f5ea 100644 --- a/testsuite/tests/typing-modules/pr7726.ml +++ b/testsuite/tests/typing-modules/pr7726.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module type T = sig type t end diff --git a/testsuite/tests/typing-modules/pr7787.ml b/testsuite/tests/typing-modules/pr7787.ml index 4738df3876..ccb32cfd8d 100644 --- a/testsuite/tests/typing-modules/pr7787.ml +++ b/testsuite/tests/typing-modules/pr7787.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module O (T : sig diff --git a/testsuite/tests/typing-modules/pr7818.ml b/testsuite/tests/typing-modules/pr7818.ml index eea55e3f7d..e6e03298a2 100644 --- a/testsuite/tests/typing-modules/pr7818.ml +++ b/testsuite/tests/typing-modules/pr7818.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* cannot_alias.ml *) diff --git a/testsuite/tests/typing-modules/pr7851.ml b/testsuite/tests/typing-modules/pr7851.ml index 9e1eef73a1..f19c1c108a 100644 --- a/testsuite/tests/typing-modules/pr7851.ml +++ b/testsuite/tests/typing-modules/pr7851.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* Leo's version *) diff --git a/testsuite/tests/typing-modules/pr8810.ml b/testsuite/tests/typing-modules/pr8810.ml index 57bfa17fc7..58a07c2f3b 100644 --- a/testsuite/tests/typing-modules/pr8810.ml +++ b/testsuite/tests/typing-modules/pr8810.ml @@ -1,7 +1,7 @@ (* TEST -* setup-ocamlc.byte-build-env -flags = "-no-alias-deps -w -49 -c" -** ocamlc.byte -ocamlc_byte_exit_status = "2" + flags = "-no-alias-deps -w -49 -c"; + setup-ocamlc.byte-build-env; + ocamlc_byte_exit_status = "2"; + ocamlc.byte; *) module Loop = Pr8810 diff --git a/testsuite/tests/typing-modules/pr9384.ml b/testsuite/tests/typing-modules/pr9384.ml index 941bdadfdd..ba55288c80 100644 --- a/testsuite/tests/typing-modules/pr9384.ml +++ b/testsuite/tests/typing-modules/pr9384.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module M : sig diff --git a/testsuite/tests/typing-modules/pr9695.ml b/testsuite/tests/typing-modules/pr9695.ml index ad025fead2..c77c222fba 100644 --- a/testsuite/tests/typing-modules/pr9695.ml +++ b/testsuite/tests/typing-modules/pr9695.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module Test (S : sig module type S end) (M : S.S) = diff --git a/testsuite/tests/typing-modules/printing.ml b/testsuite/tests/typing-modules/printing.ml index 796431507e..1cd554ef00 100644 --- a/testsuite/tests/typing-modules/printing.ml +++ b/testsuite/tests/typing-modules/printing.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* PR#6650 *) diff --git a/testsuite/tests/typing-modules/private.ml b/testsuite/tests/typing-modules/private.ml index 940c1eb6a9..202b90e9e1 100644 --- a/testsuite/tests/typing-modules/private.ml +++ b/testsuite/tests/typing-modules/private.ml @@ -1,6 +1,6 @@ (* TEST - * expect - *) + expect; +*) module M : sig type t = private [< `A | `B of string] end diff --git a/testsuite/tests/typing-modules/records_errors_test.ml b/testsuite/tests/typing-modules/records_errors_test.ml index ef327db4eb..a691a3e7e5 100644 --- a/testsuite/tests/typing-modules/records_errors_test.ml +++ b/testsuite/tests/typing-modules/records_errors_test.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module M1 : sig diff --git a/testsuite/tests/typing-modules/recursive.ml b/testsuite/tests/typing-modules/recursive.ml index 23ad13013e..35e4e88bd3 100644 --- a/testsuite/tests/typing-modules/recursive.ml +++ b/testsuite/tests/typing-modules/recursive.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* PR#7324 *) diff --git a/testsuite/tests/typing-modules/struct_include_optimisation.ml b/testsuite/tests/typing-modules/struct_include_optimisation.ml index 264af898fc..b5f205204f 100644 --- a/testsuite/tests/typing-modules/struct_include_optimisation.ml +++ b/testsuite/tests/typing-modules/struct_include_optimisation.ml @@ -1,5 +1,6 @@ (* TEST - * native *) + native; +*) type alloc_count = { mutable total: float } let allocs = Sys.opaque_identity { total = 0. } let[@inline never] set_allocs () = diff --git a/testsuite/tests/typing-modules/unroll_private_abbrev.ml b/testsuite/tests/typing-modules/unroll_private_abbrev.ml index 4fa7f7da2f..cb9bf74d5d 100644 --- a/testsuite/tests/typing-modules/unroll_private_abbrev.ml +++ b/testsuite/tests/typing-modules/unroll_private_abbrev.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module M : sig diff --git a/testsuite/tests/typing-modules/variants_errors_test.ml b/testsuite/tests/typing-modules/variants_errors_test.ml index 253bc080e2..dab5ad9541 100644 --- a/testsuite/tests/typing-modules/variants_errors_test.ml +++ b/testsuite/tests/typing-modules/variants_errors_test.ml @@ -1,6 +1,6 @@ (* TEST - * expect - *) + expect; +*) module M1 : sig type t = diff --git a/testsuite/tests/typing-modules/with_ghosts.ml b/testsuite/tests/typing-modules/with_ghosts.ml index ab9ad14fa9..8824054fce 100644 --- a/testsuite/tests/typing-modules/with_ghosts.ml +++ b/testsuite/tests/typing-modules/with_ghosts.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (** diff --git a/testsuite/tests/typing-multifile/pr6372.ml b/testsuite/tests/typing-multifile/pr6372.ml index 74457647da..fd148a1603 100644 --- a/testsuite/tests/typing-multifile/pr6372.ml +++ b/testsuite/tests/typing-multifile/pr6372.ml @@ -1,9 +1,9 @@ (* TEST -readonly_files = "d.mli e.ml" -* setup-ocamlc.byte-build-env -** ocamlc.byte -module = "d.mli" -*** ocamlc.byte -module = "e.ml" -**** check-ocamlc.byte-output + readonly_files = "d.mli e.ml"; + setup-ocamlc.byte-build-env; + module = "d.mli"; + ocamlc.byte; + module = "e.ml"; + ocamlc.byte; + check-ocamlc.byte-output; *) diff --git a/testsuite/tests/typing-multifile/pr7325.ml b/testsuite/tests/typing-multifile/pr7325.ml index 87cad1ab54..a30178f8e2 100644 --- a/testsuite/tests/typing-multifile/pr7325.ml +++ b/testsuite/tests/typing-multifile/pr7325.ml @@ -1,13 +1,13 @@ (* TEST -readonly_files = "a.ml b.ml c.ml" -* setup-ocamlc.byte-build-env -** ocamlc.byte -module = "a.ml" -*** ocamlc.byte -module = "b.ml" -**** script -script = "rm a.cmi" -***** ocamlc.byte -module = "c.ml" -****** check-ocamlc.byte-output + readonly_files = "a.ml b.ml c.ml"; + setup-ocamlc.byte-build-env; + module = "a.ml"; + ocamlc.byte; + module = "b.ml"; + ocamlc.byte; + script = "rm a.cmi"; + script; + module = "c.ml"; + ocamlc.byte; + check-ocamlc.byte-output; *) diff --git a/testsuite/tests/typing-multifile/pr7563.ml b/testsuite/tests/typing-multifile/pr7563.ml index d7950efbea..87c8491dd3 100644 --- a/testsuite/tests/typing-multifile/pr7563.ml +++ b/testsuite/tests/typing-multifile/pr7563.ml @@ -1,5 +1,5 @@ (* TEST -modules = "f.ml" + modules = "f.ml"; *) exit (if F.Alias = F.alias then 0 else 1) diff --git a/testsuite/tests/typing-multifile/pr9218.ml b/testsuite/tests/typing-multifile/pr9218.ml index 3c025aff37..c2fb461a98 100644 --- a/testsuite/tests/typing-multifile/pr9218.ml +++ b/testsuite/tests/typing-multifile/pr9218.ml @@ -1,7 +1,7 @@ (* TEST - flags="-annot" - modules="a.ml" - *) + flags = "-annot"; + modules = "a.ml"; +*) (* Test interference between inline record path [a.A] and the [a.ml] compilation unit *) diff --git a/testsuite/tests/typing-objects-bugs/pr3968_bad.ml b/testsuite/tests/typing-objects-bugs/pr3968_bad.ml index e60b35044f..02094f0a6e 100644 --- a/testsuite/tests/typing-objects-bugs/pr3968_bad.ml +++ b/testsuite/tests/typing-objects-bugs/pr3968_bad.ml @@ -1,9 +1,9 @@ -(* TEST -flags = " -w -a " -ocamlc_byte_exit_status = "2" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) type expr = @@ -27,3 +27,11 @@ object body | _ -> `App(l,r); end + +(* TEST + flags = " -w -a "; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/typing-objects-bugs/pr4018_bad.ml b/testsuite/tests/typing-objects-bugs/pr4018_bad.ml index a2a7235fef..6142ea8a82 100644 --- a/testsuite/tests/typing-objects-bugs/pr4018_bad.ml +++ b/testsuite/tests/typing-objects-bugs/pr4018_bad.ml @@ -1,9 +1,9 @@ -(* TEST -flags = " -w -a " -ocamlc_byte_exit_status = "2" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) class virtual ['subject, 'event] observer = @@ -51,3 +51,11 @@ class world = end *) + +(* TEST + flags = " -w -a "; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/typing-objects-bugs/pr4435_bad.ml b/testsuite/tests/typing-objects-bugs/pr4435_bad.ml index 9cbd777ee4..fb2e486895 100644 --- a/testsuite/tests/typing-objects-bugs/pr4435_bad.ml +++ b/testsuite/tests/typing-objects-bugs/pr4435_bad.ml @@ -1,9 +1,9 @@ -(* TEST -flags = " -w -a " -ocamlc_byte_exit_status = "2" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) (* Two v's in the same class *) @@ -17,3 +17,11 @@ class c (v : int) = inherit ((fun v -> object method v : string = v end) "42") end;; (new c 42)#v0;; + +(* TEST + flags = " -w -a "; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/typing-objects-bugs/pr4766_ok.ml b/testsuite/tests/typing-objects-bugs/pr4766_ok.ml index 565275a499..fd240ee226 100644 --- a/testsuite/tests/typing-objects-bugs/pr4766_ok.ml +++ b/testsuite/tests/typing-objects-bugs/pr4766_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) class virtual ['a] c = diff --git a/testsuite/tests/typing-objects-bugs/pr4824_ok.ml b/testsuite/tests/typing-objects-bugs/pr4824_ok.ml index 114a5a7534..09748aef1d 100644 --- a/testsuite/tests/typing-objects-bugs/pr4824_ok.ml +++ b/testsuite/tests/typing-objects-bugs/pr4824_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) module M : diff --git a/testsuite/tests/typing-objects-bugs/pr4824a_bad.ml b/testsuite/tests/typing-objects-bugs/pr4824a_bad.ml index 566cd0c771..cdd6486087 100644 --- a/testsuite/tests/typing-objects-bugs/pr4824a_bad.ml +++ b/testsuite/tests/typing-objects-bugs/pr4824a_bad.ml @@ -1,9 +1,9 @@ -(* TEST -flags = " -w -a " -ocamlc_byte_exit_status = "2" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) module M : sig class c : 'a -> object val x : 'b end end = @@ -12,3 +12,11 @@ module M : sig class c : 'a -> object val x : 'b end end = class c (x : int) = object inherit M.c x method x : bool = x end let r = (new c 2)#x;; + +(* TEST + flags = " -w -a "; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/typing-objects-bugs/pr5156_ok.ml b/testsuite/tests/typing-objects-bugs/pr5156_ok.ml index e17bf711d2..d3e85071a5 100644 --- a/testsuite/tests/typing-objects-bugs/pr5156_ok.ml +++ b/testsuite/tests/typing-objects-bugs/pr5156_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) class type t = object end;; diff --git a/testsuite/tests/typing-objects-bugs/pr7284_bad.ml b/testsuite/tests/typing-objects-bugs/pr7284_bad.ml index ab7bc55d82..a868d5bc00 100644 --- a/testsuite/tests/typing-objects-bugs/pr7284_bad.ml +++ b/testsuite/tests/typing-objects-bugs/pr7284_bad.ml @@ -1,9 +1,9 @@ -(* TEST -flags = " -w -a " -ocamlc_byte_exit_status = "2" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) module type S = sig @@ -39,3 +39,11 @@ module type S = sig module N = F(M) let () = N.f (N.V2 0) + +(* TEST + flags = " -w -a "; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/typing-objects-bugs/pr7293_ok.ml b/testsuite/tests/typing-objects-bugs/pr7293_ok.ml index 40ba424e05..ae796dc03a 100644 --- a/testsuite/tests/typing-objects-bugs/pr7293_ok.ml +++ b/testsuite/tests/typing-objects-bugs/pr7293_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) type t = T : t diff --git a/testsuite/tests/typing-objects-bugs/woodyatt_ok.ml b/testsuite/tests/typing-objects-bugs/woodyatt_ok.ml index a109ed052c..b56953cdbd 100644 --- a/testsuite/tests/typing-objects-bugs/woodyatt_ok.ml +++ b/testsuite/tests/typing-objects-bugs/woodyatt_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) (* test.ml *) diff --git a/testsuite/tests/typing-objects-bugs/yamagata021012_ok.ml b/testsuite/tests/typing-objects-bugs/yamagata021012_ok.ml index eb7ed2a72a..fa4579ce24 100644 --- a/testsuite/tests/typing-objects-bugs/yamagata021012_ok.ml +++ b/testsuite/tests/typing-objects-bugs/yamagata021012_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) (* The module begins *) diff --git a/testsuite/tests/typing-objects/Exemples.ml b/testsuite/tests/typing-objects/Exemples.ml index 3ab4072c14..513b28d13d 100644 --- a/testsuite/tests/typing-objects/Exemples.ml +++ b/testsuite/tests/typing-objects/Exemples.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) class point x_init = object diff --git a/testsuite/tests/typing-objects/Tests.ml b/testsuite/tests/typing-objects/Tests.ml index e196362bcc..c671375805 100644 --- a/testsuite/tests/typing-objects/Tests.ml +++ b/testsuite/tests/typing-objects/Tests.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* Subtyping is "syntactic" *) diff --git a/testsuite/tests/typing-objects/abstract_rows.ml b/testsuite/tests/typing-objects/abstract_rows.ml index 0ae3d307a2..3b92692530 100644 --- a/testsuite/tests/typing-objects/abstract_rows.ml +++ b/testsuite/tests/typing-objects/abstract_rows.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type u = <x:int> type t = private <u; ..> diff --git a/testsuite/tests/typing-objects/class_2.ml b/testsuite/tests/typing-objects/class_2.ml index 2d70884cdd..0944768382 100644 --- a/testsuite/tests/typing-objects/class_2.ml +++ b/testsuite/tests/typing-objects/class_2.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* class expressions may also contain local recursive bindings *) diff --git a/testsuite/tests/typing-objects/dummy.ml b/testsuite/tests/typing-objects/dummy.ml index de8b18822a..d85c5d102a 100644 --- a/testsuite/tests/typing-objects/dummy.ml +++ b/testsuite/tests/typing-objects/dummy.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) class virtual child1 parent = diff --git a/testsuite/tests/typing-objects/errors.ml b/testsuite/tests/typing-objects/errors.ml index 236f7e1d5b..eb839fee15 100644 --- a/testsuite/tests/typing-objects/errors.ml +++ b/testsuite/tests/typing-objects/errors.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) class type virtual ['a] c = object constraint 'a = [<`A of int & float] end diff --git a/testsuite/tests/typing-objects/field_kind.ml b/testsuite/tests/typing-objects/field_kind.ml index 287e3c6770..53dea44bac 100644 --- a/testsuite/tests/typing-objects/field_kind.ml +++ b/testsuite/tests/typing-objects/field_kind.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type _ t = Int : int t;; diff --git a/testsuite/tests/typing-objects/nongen.ml b/testsuite/tests/typing-objects/nongen.ml index acbd296581..f4937be122 100644 --- a/testsuite/tests/typing-objects/nongen.ml +++ b/testsuite/tests/typing-objects/nongen.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) let x = ref None diff --git a/testsuite/tests/typing-objects/open_in_classes.ml b/testsuite/tests/typing-objects/open_in_classes.ml index 05f33b9192..f374c08393 100644 --- a/testsuite/tests/typing-objects/open_in_classes.ml +++ b/testsuite/tests/typing-objects/open_in_classes.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module M = struct diff --git a/testsuite/tests/typing-objects/pr11569.ml b/testsuite/tests/typing-objects/pr11569.ml index 321f0a9b25..70d303852b 100644 --- a/testsuite/tests/typing-objects/pr11569.ml +++ b/testsuite/tests/typing-objects/pr11569.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) class ['a] c = object constraint 'a = int method m (x: bool #c) = () end;; diff --git a/testsuite/tests/typing-objects/pr5545.ml b/testsuite/tests/typing-objects/pr5545.ml index 8bb92adfda..c0ec1b71ee 100644 --- a/testsuite/tests/typing-objects/pr5545.ml +++ b/testsuite/tests/typing-objects/pr5545.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type foo = int;; diff --git a/testsuite/tests/typing-objects/pr5619_bad.ml b/testsuite/tests/typing-objects/pr5619_bad.ml index bfbf6dd861..766f5adc87 100644 --- a/testsuite/tests/typing-objects/pr5619_bad.ml +++ b/testsuite/tests/typing-objects/pr5619_bad.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) class type foo_t = diff --git a/testsuite/tests/typing-objects/pr5858.ml b/testsuite/tests/typing-objects/pr5858.ml index a7f0bf84b3..6fa0162a86 100644 --- a/testsuite/tests/typing-objects/pr5858.ml +++ b/testsuite/tests/typing-objects/pr5858.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) class type c = object end;; diff --git a/testsuite/tests/typing-objects/pr6123_bad.ml b/testsuite/tests/typing-objects/pr6123_bad.ml index 6dff6598ff..066ae48472 100644 --- a/testsuite/tests/typing-objects/pr6123_bad.ml +++ b/testsuite/tests/typing-objects/pr6123_bad.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) class virtual name = diff --git a/testsuite/tests/typing-objects/pr6383.ml b/testsuite/tests/typing-objects/pr6383.ml index 12bc876ed8..3f9e701d30 100644 --- a/testsuite/tests/typing-objects/pr6383.ml +++ b/testsuite/tests/typing-objects/pr6383.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) let f (x: #M.foo) = 0;; diff --git a/testsuite/tests/typing-objects/pr6907_bad.ml b/testsuite/tests/typing-objects/pr6907_bad.ml index cafe04f440..7b5da5ba68 100644 --- a/testsuite/tests/typing-objects/pr6907_bad.ml +++ b/testsuite/tests/typing-objects/pr6907_bad.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) class type ['e] t = object('s) diff --git a/testsuite/tests/typing-objects/pr7711_ok.ml b/testsuite/tests/typing-objects/pr7711_ok.ml index 7f188cf59b..3f910e7f16 100644 --- a/testsuite/tests/typing-objects/pr7711_ok.ml +++ b/testsuite/tests/typing-objects/pr7711_ok.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type 'a r = <w: int -> int; .. > as 'a;; diff --git a/testsuite/tests/typing-objects/self_cannot_be_closed.ml b/testsuite/tests/typing-objects/self_cannot_be_closed.ml index f2cbc406b1..ccd0f91832 100644 --- a/testsuite/tests/typing-objects/self_cannot_be_closed.ml +++ b/testsuite/tests/typing-objects/self_cannot_be_closed.ml @@ -1,6 +1,6 @@ (* TEST - * expect - *) + expect; +*) let is_empty (x : < >) = ();; [%%expect {| val is_empty : < > -> unit = <fun> diff --git a/testsuite/tests/typing-objects/self_cannot_escape_pr7865.ml b/testsuite/tests/typing-objects/self_cannot_escape_pr7865.ml index d350fbb52c..c192a16cfe 100644 --- a/testsuite/tests/typing-objects/self_cannot_escape_pr7865.ml +++ b/testsuite/tests/typing-objects/self_cannot_escape_pr7865.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) class c = diff --git a/testsuite/tests/typing-objects/unbound-type-var.ml b/testsuite/tests/typing-objects/unbound-type-var.ml index 9e00cea202..1a533cac91 100644 --- a/testsuite/tests/typing-objects/unbound-type-var.ml +++ b/testsuite/tests/typing-objects/unbound-type-var.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) class test a c = diff --git a/testsuite/tests/typing-ocamlc-i/pervasives_leitmotiv.ml b/testsuite/tests/typing-ocamlc-i/pervasives_leitmotiv.ml index f6ec3f9b1d..32bbfde36d 100644 --- a/testsuite/tests/typing-ocamlc-i/pervasives_leitmotiv.ml +++ b/testsuite/tests/typing-ocamlc-i/pervasives_leitmotiv.ml @@ -1,8 +1,8 @@ -(* TEST -flags = "-i -w +63" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + *) type fpclass = A @@ -12,3 +12,10 @@ module Stdlib = struct end let f A Stdlib.B = FP_normal + +(* TEST + flags = "-i -w +63"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/typing-ocamlc-i/pr4791.ml b/testsuite/tests/typing-ocamlc-i/pr4791.ml index f781017001..953e44e933 100644 --- a/testsuite/tests/typing-ocamlc-i/pr4791.ml +++ b/testsuite/tests/typing-ocamlc-i/pr4791.ml @@ -1,8 +1,8 @@ -(* TEST -flags = "-i -w +63" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + *) type t = A @@ -11,3 +11,10 @@ struct type t = B let f A = B end + +(* TEST + flags = "-i -w +63"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/typing-ocamlc-i/pr6323.ml b/testsuite/tests/typing-ocamlc-i/pr6323.ml index 7aff93f1fa..6084550d13 100644 --- a/testsuite/tests/typing-ocamlc-i/pr6323.ml +++ b/testsuite/tests/typing-ocamlc-i/pr6323.ml @@ -1,8 +1,8 @@ -(* TEST -flags = "-i -w +63" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + *) type 'a t = B of 'a t list @@ -15,3 +15,10 @@ module DT = struct type 'a t = {bar : 'a} let p t = foo (fun x -> x) t end + +(* TEST + flags = "-i -w +63"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/typing-ocamlc-i/pr7402.ml b/testsuite/tests/typing-ocamlc-i/pr7402.ml index b1ccef885e..38b52e8fad 100644 --- a/testsuite/tests/typing-ocamlc-i/pr7402.ml +++ b/testsuite/tests/typing-ocamlc-i/pr7402.ml @@ -1,8 +1,8 @@ -(* TEST -flags = "-i -w +63" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + *) module M: sig type t val v:t end = struct @@ -17,3 +17,10 @@ module M = struct let v = M.v end + +(* TEST + flags = "-i -w +63"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/typing-ocamlc-i/pr7620_bad.ml b/testsuite/tests/typing-ocamlc-i/pr7620_bad.ml index 25d199a64e..2775db7e9c 100644 --- a/testsuite/tests/typing-ocamlc-i/pr7620_bad.ml +++ b/testsuite/tests/typing-ocamlc-i/pr7620_bad.ml @@ -1,11 +1,19 @@ -(* TEST -flags = "-i" -ocamlc_byte_exit_status = "2" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) let t = (function `A | `B -> () : 'a) (`A : [`A]); (failwith "dummy" : 'a) (* to know how 'a is unified *) + +(* TEST + flags = "-i"; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/typing-poly-bugs/pr5322_ok.ml b/testsuite/tests/typing-poly-bugs/pr5322_ok.ml index 7534c64f3e..f6523107b8 100644 --- a/testsuite/tests/typing-poly-bugs/pr5322_ok.ml +++ b/testsuite/tests/typing-poly-bugs/pr5322_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) type 'par t = 'par diff --git a/testsuite/tests/typing-poly-bugs/pr5673_ok.ml b/testsuite/tests/typing-poly-bugs/pr5673_ok.ml index f30487b18d..73151ec9eb 100644 --- a/testsuite/tests/typing-poly-bugs/pr5673_ok.ml +++ b/testsuite/tests/typing-poly-bugs/pr5673_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) module Classdef = struct diff --git a/testsuite/tests/typing-poly-bugs/pr6922_ok.ml b/testsuite/tests/typing-poly-bugs/pr6922_ok.ml index a251762ede..f05f09f8a9 100644 --- a/testsuite/tests/typing-poly-bugs/pr6922_ok.ml +++ b/testsuite/tests/typing-poly-bugs/pr6922_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) module Order = struct diff --git a/testsuite/tests/typing-poly/error_messages.ml b/testsuite/tests/typing-poly/error_messages.ml index 02a6b748f7..d25f972844 100644 --- a/testsuite/tests/typing-poly/error_messages.ml +++ b/testsuite/tests/typing-poly/error_messages.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type t = < x : 'a. int as 'a > diff --git a/testsuite/tests/typing-poly/poly.ml b/testsuite/tests/typing-poly/poly.ml index bcb8abf554..4d84a44248 100644 --- a/testsuite/tests/typing-poly/poly.ml +++ b/testsuite/tests/typing-poly/poly.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* diff --git a/testsuite/tests/typing-poly/pr7636.ml b/testsuite/tests/typing-poly/pr7636.ml index 16074ab5ee..1c4ef67ccb 100644 --- a/testsuite/tests/typing-poly/pr7636.ml +++ b/testsuite/tests/typing-poly/pr7636.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module M = struct diff --git a/testsuite/tests/typing-poly/pr9603.ml b/testsuite/tests/typing-poly/pr9603.ml index 02f1e921b9..9e48b344c5 100644 --- a/testsuite/tests/typing-poly/pr9603.ml +++ b/testsuite/tests/typing-poly/pr9603.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type 'p pair = 'a * 'b constraint 'p = < left:'a; right:'b> diff --git a/testsuite/tests/typing-polyvariants-bugs-2/pr3918c.ml b/testsuite/tests/typing-polyvariants-bugs-2/pr3918c.ml index 7eabcd700b..5475dfe11e 100644 --- a/testsuite/tests/typing-polyvariants-bugs-2/pr3918c.ml +++ b/testsuite/tests/typing-polyvariants-bugs-2/pr3918c.ml @@ -1,16 +1,16 @@ -(* TEST -readonly_files = "pr3918a.mli pr3918b.mli" -* setup-ocamlc.byte-build-env -** ocamlc.byte -module = "pr3918a.mli" -*** ocamlc.byte -module = "pr3918b.mli" -**** script -script = "rm -f pr3918a.cmi" -***** ocamlc.byte -module = "pr3918c.ml" -ocamlc_byte_exit_status = "2" -***** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + + + + + + + + *) (* @@ -23,3 +23,21 @@ open Pr3918b let f x = (x : 'a vlist :> 'b vlist) let f (x : 'a vlist) = (x : 'b vlist) + +(* TEST + readonly_files = "pr3918a.mli pr3918b.mli"; + setup-ocamlc.byte-build-env; + module = "pr3918a.mli"; + ocamlc.byte; + module = "pr3918b.mli"; + ocamlc.byte; + script = "rm -f pr3918a.cmi"; + script; + { + module = "pr3918c.ml"; + ocamlc_byte_exit_status = "2"; + ocamlc.byte; + }{ + check-ocamlc.byte-output; + } +*) diff --git a/testsuite/tests/typing-polyvariants-bugs/pr10664.ml b/testsuite/tests/typing-polyvariants-bugs/pr10664.ml index 1957e1fce6..109e1c5df2 100644 --- a/testsuite/tests/typing-polyvariants-bugs/pr10664.ml +++ b/testsuite/tests/typing-polyvariants-bugs/pr10664.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) class idfunc = object diff --git a/testsuite/tests/typing-polyvariants-bugs/pr10664a.ml b/testsuite/tests/typing-polyvariants-bugs/pr10664a.ml index 7993e10a40..115f810ced 100644 --- a/testsuite/tests/typing-polyvariants-bugs/pr10664a.ml +++ b/testsuite/tests/typing-polyvariants-bugs/pr10664a.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) class idfunc = diff --git a/testsuite/tests/typing-polyvariants-bugs/pr4775_ok.ml b/testsuite/tests/typing-polyvariants-bugs/pr4775_ok.ml index e5d5f5978e..bdbf3c438d 100644 --- a/testsuite/tests/typing-polyvariants-bugs/pr4775_ok.ml +++ b/testsuite/tests/typing-polyvariants-bugs/pr4775_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) module type Poly = sig diff --git a/testsuite/tests/typing-polyvariants-bugs/pr4933_ok.ml b/testsuite/tests/typing-polyvariants-bugs/pr4933_ok.ml index 7a0bffcd54..b9f49b63ea 100644 --- a/testsuite/tests/typing-polyvariants-bugs/pr4933_ok.ml +++ b/testsuite/tests/typing-polyvariants-bugs/pr4933_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) module type Priv = sig diff --git a/testsuite/tests/typing-polyvariants-bugs/pr5057_ok.ml b/testsuite/tests/typing-polyvariants-bugs/pr5057_ok.ml index 355eecd3ab..cbc0b5a6a2 100644 --- a/testsuite/tests/typing-polyvariants-bugs/pr5057_ok.ml +++ b/testsuite/tests/typing-polyvariants-bugs/pr5057_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) (* PR5057 *) diff --git a/testsuite/tests/typing-polyvariants-bugs/pr5057a_bad.ml b/testsuite/tests/typing-polyvariants-bugs/pr5057a_bad.ml index fa61001722..85a11060c4 100644 --- a/testsuite/tests/typing-polyvariants-bugs/pr5057a_bad.ml +++ b/testsuite/tests/typing-polyvariants-bugs/pr5057a_bad.ml @@ -1,9 +1,9 @@ -(* TEST -flags = " -w -a " -ocamlc_byte_exit_status = "2" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) (* This one should fail *) @@ -13,3 +13,11 @@ let f flag = let _ = match flag with `A -> 0 | `B r -> r in let _ = match flag with `A -> T.mem | `B r -> r in () + +(* TEST + flags = " -w -a "; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/typing-polyvariants-bugs/pr7199_ok.ml b/testsuite/tests/typing-polyvariants-bugs/pr7199_ok.ml index 75ef0cce6a..2f8d2d0217 100644 --- a/testsuite/tests/typing-polyvariants-bugs/pr7199_ok.ml +++ b/testsuite/tests/typing-polyvariants-bugs/pr7199_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) module type S = sig diff --git a/testsuite/tests/typing-polyvariants-bugs/pr7817_bad.ml b/testsuite/tests/typing-polyvariants-bugs/pr7817_bad.ml index 999420fd2b..99ae350930 100644 --- a/testsuite/tests/typing-polyvariants-bugs/pr7817_bad.ml +++ b/testsuite/tests/typing-polyvariants-bugs/pr7817_bad.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) let r = ref None diff --git a/testsuite/tests/typing-polyvariants-bugs/pr7824.ml b/testsuite/tests/typing-polyvariants-bugs/pr7824.ml index a58c9ddc98..f2901c3bb9 100644 --- a/testsuite/tests/typing-polyvariants-bugs/pr7824.ml +++ b/testsuite/tests/typing-polyvariants-bugs/pr7824.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module Element : sig diff --git a/testsuite/tests/typing-polyvariants-bugs/pr8575.ml b/testsuite/tests/typing-polyvariants-bugs/pr8575.ml index 98a70d80c1..1cb1bc3b38 100644 --- a/testsuite/tests/typing-polyvariants-bugs/pr8575.ml +++ b/testsuite/tests/typing-polyvariants-bugs/pr8575.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module A = struct type t = A | B let x = B end;; diff --git a/testsuite/tests/typing-polyvariants-bugs/privrowsabate_ok.ml b/testsuite/tests/typing-polyvariants-bugs/privrowsabate_ok.ml index 9274c9d4af..4858be18b4 100644 --- a/testsuite/tests/typing-polyvariants-bugs/privrowsabate_ok.ml +++ b/testsuite/tests/typing-polyvariants-bugs/privrowsabate_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) type 'a termpc = diff --git a/testsuite/tests/typing-private-bugs/pr5026_bad.ml b/testsuite/tests/typing-private-bugs/pr5026_bad.ml index c62a3cb99c..cc3509b242 100644 --- a/testsuite/tests/typing-private-bugs/pr5026_bad.ml +++ b/testsuite/tests/typing-private-bugs/pr5026_bad.ml @@ -1,9 +1,9 @@ -(* TEST -flags = " -w -a " -ocamlc_byte_exit_status = "2" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) type untyped;; @@ -17,3 +17,11 @@ end;; class ['a] s3object r : ['a] s3 = object val underlying = r end;; + +(* TEST + flags = " -w -a "; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/typing-private-bugs/pr5469_ok.ml b/testsuite/tests/typing-private-bugs/pr5469_ok.ml index a5f36390a7..faa2eaa4ad 100644 --- a/testsuite/tests/typing-private-bugs/pr5469_ok.ml +++ b/testsuite/tests/typing-private-bugs/pr5469_ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) module M (T:sig type t end) diff --git a/testsuite/tests/typing-private/invalid_private_row.ml b/testsuite/tests/typing-private/invalid_private_row.ml index 361b982c11..18ec0fc71d 100644 --- a/testsuite/tests/typing-private/invalid_private_row.ml +++ b/testsuite/tests/typing-private/invalid_private_row.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (** Error message for trying to make private a row type variable diff --git a/testsuite/tests/typing-private/private.ml b/testsuite/tests/typing-private/private.ml index 156e9ba51d..bd2b9da5e9 100644 --- a/testsuite/tests/typing-private/private.ml +++ b/testsuite/tests/typing-private/private.ml @@ -1,6 +1,9 @@ (* TEST - * toplevel - * toplevel with principal + { + toplevel; + }{ + toplevel with principal; + } *) module Foobar : sig diff --git a/testsuite/tests/typing-recmod/gpr1626.ml b/testsuite/tests/typing-recmod/gpr1626.ml index 9629f2c603..69429ec142 100644 --- a/testsuite/tests/typing-recmod/gpr1626.ml +++ b/testsuite/tests/typing-recmod/gpr1626.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module type S = sig module M : sig end module N = M end;; diff --git a/testsuite/tests/typing-recmod/pr6491.ml b/testsuite/tests/typing-recmod/pr6491.ml index 410c11b364..8d6e673902 100644 --- a/testsuite/tests/typing-recmod/pr6491.ml +++ b/testsuite/tests/typing-recmod/pr6491.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module rec Foo : sig class type c = object method x : int end end = Foo diff --git a/testsuite/tests/typing-recmod/pr9494.ml b/testsuite/tests/typing-recmod/pr9494.ml index 41fda6aa15..2b5c17d025 100644 --- a/testsuite/tests/typing-recmod/pr9494.ml +++ b/testsuite/tests/typing-recmod/pr9494.ml @@ -1,5 +1,5 @@ -(* TEST -*) +(* TEST_BELOW +(* Blank lines added here to preserve locations. *)*) (* PR#9494 *) @@ -36,3 +36,6 @@ let _ = try let basic_set = IdSet.singleton {id = 0} in IdSet.mem {id = 1} basic_set (* diverge here *) with e -> print_endline @@ Printexc.to_string e; false + +(* TEST +*) diff --git a/testsuite/tests/typing-recmod/t01bad.ml b/testsuite/tests/typing-recmod/t01bad.ml index 5bf6197f37..faedd9f2e8 100644 --- a/testsuite/tests/typing-recmod/t01bad.ml +++ b/testsuite/tests/typing-recmod/t01bad.ml @@ -1,10 +1,18 @@ -(* TEST -flags = " -w -a " -ocamlc_byte_exit_status = "2" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) (* Bad (t = t) *) module rec A : sig type t = A.t end = struct type t = A.t end;; + +(* TEST + flags = " -w -a "; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/typing-recmod/t02bad.ml b/testsuite/tests/typing-recmod/t02bad.ml index 1faba72b87..9a52879bcd 100644 --- a/testsuite/tests/typing-recmod/t02bad.ml +++ b/testsuite/tests/typing-recmod/t02bad.ml @@ -1,11 +1,19 @@ -(* TEST -flags = " -w -a " -ocamlc_byte_exit_status = "2" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) (* Bad (t = t) *) module rec A : sig type t = B.t end = struct type t = B.t end and B : sig type t = A.t end = struct type t = A.t end;; + +(* TEST + flags = " -w -a "; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/typing-recmod/t03ok.ml b/testsuite/tests/typing-recmod/t03ok.ml index a1c9b32a95..94e4a09f32 100644 --- a/testsuite/tests/typing-recmod/t03ok.ml +++ b/testsuite/tests/typing-recmod/t03ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) (* OK (t = int) *) diff --git a/testsuite/tests/typing-recmod/t04bad.ml b/testsuite/tests/typing-recmod/t04bad.ml index a671b414d4..6f39c910e1 100644 --- a/testsuite/tests/typing-recmod/t04bad.ml +++ b/testsuite/tests/typing-recmod/t04bad.ml @@ -1,10 +1,18 @@ -(* TEST -flags = " -w -a " -ocamlc_byte_exit_status = "2" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) (* Bad (t = int * t) *) module rec A : sig type t = int * A.t end = struct type t = int * A.t end;; + +(* TEST + flags = " -w -a "; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/typing-recmod/t05bad.ml b/testsuite/tests/typing-recmod/t05bad.ml index 1f1df6c590..94d4fc2587 100644 --- a/testsuite/tests/typing-recmod/t05bad.ml +++ b/testsuite/tests/typing-recmod/t05bad.ml @@ -1,11 +1,19 @@ -(* TEST -flags = " -w -a " -ocamlc_byte_exit_status = "2" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) (* Bad (t = t -> int) *) module rec A : sig type t = B.t -> int end = struct type t = B.t -> int end and B : sig type t = A.t end = struct type t = A.t end;; + +(* TEST + flags = " -w -a "; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/typing-recmod/t06ok.ml b/testsuite/tests/typing-recmod/t06ok.ml index a0cfebdbc2..c39b0fa99a 100644 --- a/testsuite/tests/typing-recmod/t06ok.ml +++ b/testsuite/tests/typing-recmod/t06ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) (* OK (t = <m:t>) *) diff --git a/testsuite/tests/typing-recmod/t07bad.ml b/testsuite/tests/typing-recmod/t07bad.ml index 27e8f1859f..61f8972253 100644 --- a/testsuite/tests/typing-recmod/t07bad.ml +++ b/testsuite/tests/typing-recmod/t07bad.ml @@ -1,11 +1,19 @@ -(* TEST -flags = " -w -a " -ocamlc_byte_exit_status = "2" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) (* Bad (not regular) *) module rec A : sig type 'a t = <m: 'a list A.t> end = struct type 'a t = <m: 'a list A.t> end;; + +(* TEST + flags = " -w -a "; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/typing-recmod/t08bad.ml b/testsuite/tests/typing-recmod/t08bad.ml index 46d2b727c4..341459a6d1 100644 --- a/testsuite/tests/typing-recmod/t08bad.ml +++ b/testsuite/tests/typing-recmod/t08bad.ml @@ -1,12 +1,20 @@ -(* TEST -flags = " -w -a " -ocamlc_byte_exit_status = "2" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) (* Bad (not regular) *) module rec A : sig type 'a t = <m: 'a list B.t; n: 'a array B.t> end = struct type 'a t = <m: 'a list B.t; n: 'a array B.t> end and B : sig type 'a t = 'a A.t end = struct type 'a t = 'a A.t end;; + +(* TEST + flags = " -w -a "; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/typing-recmod/t09bad.ml b/testsuite/tests/typing-recmod/t09bad.ml index 9ac5d3133d..21fa28620d 100644 --- a/testsuite/tests/typing-recmod/t09bad.ml +++ b/testsuite/tests/typing-recmod/t09bad.ml @@ -1,9 +1,9 @@ -(* TEST -flags = " -w -a " -ocamlc_byte_exit_status = "2" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) (* Bad (not regular) *) @@ -11,3 +11,11 @@ module rec A : sig type 'a t = 'a B.t end = struct type 'a t = 'a B.t end and B : sig type 'a t = <m: 'a list A.t; n: 'a array A.t> end = struct type 'a t = <m: 'a list A.t; n: 'a array A.t> end;; + +(* TEST + flags = " -w -a "; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/typing-recmod/t10ok.ml b/testsuite/tests/typing-recmod/t10ok.ml index 626ab888fc..8f8b376f34 100644 --- a/testsuite/tests/typing-recmod/t10ok.ml +++ b/testsuite/tests/typing-recmod/t10ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) (* OK *) diff --git a/testsuite/tests/typing-recmod/t11bad.ml b/testsuite/tests/typing-recmod/t11bad.ml index f6f2fed846..58f186ebdb 100644 --- a/testsuite/tests/typing-recmod/t11bad.ml +++ b/testsuite/tests/typing-recmod/t11bad.ml @@ -1,9 +1,9 @@ -(* TEST -flags = " -w -a " -ocamlc_byte_exit_status = "2" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) (* Bad (not regular) *) @@ -11,3 +11,11 @@ module rec A : sig type 'a t = 'a list B.t end = struct type 'a t = 'a list B.t end and B : sig type 'a t = <m: 'a array B.t> end = struct type 'a t = <m: 'a array B.t> end;; + +(* TEST + flags = " -w -a "; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/typing-recmod/t12bad.ml b/testsuite/tests/typing-recmod/t12bad.ml index cbc8c5bbaf..f7a5ec730c 100644 --- a/testsuite/tests/typing-recmod/t12bad.ml +++ b/testsuite/tests/typing-recmod/t12bad.ml @@ -1,9 +1,9 @@ -(* TEST -flags = " -w -a " -ocamlc_byte_exit_status = "2" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) (* Bad (not regular) *) @@ -19,3 +19,11 @@ module rec M : = fun f -> new M.c (f x) end end;; + +(* TEST + flags = " -w -a "; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/typing-recmod/t13ok.ml b/testsuite/tests/typing-recmod/t13ok.ml index ee50f89041..0b0eb85073 100644 --- a/testsuite/tests/typing-recmod/t13ok.ml +++ b/testsuite/tests/typing-recmod/t13ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) (* OK *) diff --git a/testsuite/tests/typing-recmod/t14bad.ml b/testsuite/tests/typing-recmod/t14bad.ml index 4fe91cccc1..ec5f926b34 100644 --- a/testsuite/tests/typing-recmod/t14bad.ml +++ b/testsuite/tests/typing-recmod/t14bad.ml @@ -1,9 +1,9 @@ -(* TEST -flags = " -w -a " -ocamlc_byte_exit_status = "2" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) (* Bad - PR 4261 *) @@ -23,3 +23,11 @@ module PR_4261 = struct module rec U : T with type D.t = U'.t = U and U' : S with type t = U'.t = U end;; + +(* TEST + flags = " -w -a "; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/typing-recmod/t15bad.ml b/testsuite/tests/typing-recmod/t15bad.ml index efb99e681e..25840b192a 100644 --- a/testsuite/tests/typing-recmod/t15bad.ml +++ b/testsuite/tests/typing-recmod/t15bad.ml @@ -1,11 +1,19 @@ -(* TEST -flags = " -w -a " -ocamlc_byte_exit_status = "2" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) (* Bad - PR 4512 *) module type S' = sig type t = int end module rec M : S' with type t = M.t = struct type t = M.t end;; + +(* TEST + flags = " -w -a "; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/typing-recmod/t16ok.ml b/testsuite/tests/typing-recmod/t16ok.ml index 1e87f4f82d..96090e147b 100644 --- a/testsuite/tests/typing-recmod/t16ok.ml +++ b/testsuite/tests/typing-recmod/t16ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) (* PR#4450 *) diff --git a/testsuite/tests/typing-recmod/t17ok.ml b/testsuite/tests/typing-recmod/t17ok.ml index 2a760d1013..3518ed71f7 100644 --- a/testsuite/tests/typing-recmod/t17ok.ml +++ b/testsuite/tests/typing-recmod/t17ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) (* A synthetic example of bootstrapped data structure diff --git a/testsuite/tests/typing-recmod/t18ok.ml b/testsuite/tests/typing-recmod/t18ok.ml index e4e3ffa611..f5309952ac 100644 --- a/testsuite/tests/typing-recmod/t18ok.ml +++ b/testsuite/tests/typing-recmod/t18ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) (* PR 4470: simplified from OMake's sources *) diff --git a/testsuite/tests/typing-recmod/t20ok.ml b/testsuite/tests/typing-recmod/t20ok.ml index ae0eed3264..5fe410f711 100644 --- a/testsuite/tests/typing-recmod/t20ok.ml +++ b/testsuite/tests/typing-recmod/t20ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) (* PR 4557 *) diff --git a/testsuite/tests/typing-recmod/t21ok.ml b/testsuite/tests/typing-recmod/t21ok.ml index 2c97da3fb9..9eb46a1209 100644 --- a/testsuite/tests/typing-recmod/t21ok.ml +++ b/testsuite/tests/typing-recmod/t21ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) module F ( X : Set.OrderedType ) = struct diff --git a/testsuite/tests/typing-recmod/t22ok.ml b/testsuite/tests/typing-recmod/t22ok.ml index 4709f23c9a..2b5b4d051d 100644 --- a/testsuite/tests/typing-recmod/t22ok.ml +++ b/testsuite/tests/typing-recmod/t22ok.ml @@ -1,8 +1,8 @@ (* TEST -flags = " -w -a " -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output + flags = " -w -a "; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; *) (* Tests for recursive modules *) diff --git a/testsuite/tests/typing-recordarg/recordarg.ml b/testsuite/tests/typing-recordarg/recordarg.ml index 5477de1e8a..7aa9939cb6 100644 --- a/testsuite/tests/typing-recordarg/recordarg.ml +++ b/testsuite/tests/typing-recordarg/recordarg.ml @@ -1,5 +1,5 @@ (* TEST - * toplevel + toplevel; *) type t = A of {x:int; mutable y:int};; diff --git a/testsuite/tests/typing-rectypes-bugs/pr5343_bad.ml b/testsuite/tests/typing-rectypes-bugs/pr5343_bad.ml index 518dafe019..e576d93197 100644 --- a/testsuite/tests/typing-rectypes-bugs/pr5343_bad.ml +++ b/testsuite/tests/typing-rectypes-bugs/pr5343_bad.ml @@ -1,9 +1,9 @@ -(* TEST -flags = " -w -a -rectypes " -ocamlc_byte_exit_status = "2" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) module M : sig @@ -19,3 +19,11 @@ end = struct end;; let h (x : int) : bool = M.g (M.f x);; + +(* TEST + flags = " -w -a -rectypes "; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/typing-rectypes-bugs/pr6174_bad.ml b/testsuite/tests/typing-rectypes-bugs/pr6174_bad.ml index d5c704416c..e0f92db7d9 100644 --- a/testsuite/tests/typing-rectypes-bugs/pr6174_bad.ml +++ b/testsuite/tests/typing-rectypes-bugs/pr6174_bad.ml @@ -1,11 +1,19 @@ -(* TEST -flags = " -w -a -rectypes " -ocamlc_byte_exit_status = "2" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) type _ t = C : ((('a -> 'o) -> 'o) -> ('b -> 'o) -> 'o) t let f : type a o. ((a -> o) -> o) t -> (a -> o) -> o = fun C k -> k (fun x -> x);; + +(* TEST + flags = " -w -a -rectypes "; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/typing-rectypes-bugs/pr6870_bad.ml b/testsuite/tests/typing-rectypes-bugs/pr6870_bad.ml index 186e07088b..a04e08eae7 100644 --- a/testsuite/tests/typing-rectypes-bugs/pr6870_bad.ml +++ b/testsuite/tests/typing-rectypes-bugs/pr6870_bad.ml @@ -1,10 +1,18 @@ -(* TEST -flags = " -w -a -rectypes " -ocamlc_byte_exit_status = "2" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + *) module type T = sig type 'a t end module Fix (T : T) = struct type r = ('r T.t as 'r) end + +(* TEST + flags = " -w -a -rectypes "; + ocamlc_byte_exit_status = "2"; + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/typing-safe-linking/b_bad.ml b/testsuite/tests/typing-safe-linking/b_bad.ml index 33eecadf6e..dd67c54a8a 100644 --- a/testsuite/tests/typing-safe-linking/b_bad.ml +++ b/testsuite/tests/typing-safe-linking/b_bad.ml @@ -1,13 +1,13 @@ -(* TEST -readonly_files = "a.ml" -* setup-ocamlc.byte-build-env -** ocamlc.byte -module = "a.ml" -*** ocamlc.byte -module = "b_bad.ml" -flags = "-warn-error +8" -ocamlc_byte_exit_status = "2" -**** check-ocamlc.byte-output +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + + + + + *) let f : string A.t -> unit = function @@ -16,3 +16,15 @@ let f : string A.t -> unit = function (* It is important that the line below is the last line of the file (see Makefile) *) let () = f A.y + +(* TEST + readonly_files = "a.ml"; + setup-ocamlc.byte-build-env; + module = "a.ml"; + ocamlc.byte; + module = "b_bad.ml"; + flags = "-warn-error +8"; + ocamlc_byte_exit_status = "2"; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/typing-shadowing-of-pervasives-submodules/redefine_largefile.ml b/testsuite/tests/typing-shadowing-of-pervasives-submodules/redefine_largefile.ml index 68401fa56e..38aed3e472 100644 --- a/testsuite/tests/typing-shadowing-of-pervasives-submodules/redefine_largefile.ml +++ b/testsuite/tests/typing-shadowing-of-pervasives-submodules/redefine_largefile.ml @@ -1,4 +1,4 @@ (* TEST - modules = "largeFile.ml" + modules = "largeFile.ml"; *) print_endline LargeFile.message diff --git a/testsuite/tests/typing-shadowing-of-pervasives-submodules/redefine_largefile_top.ml b/testsuite/tests/typing-shadowing-of-pervasives-submodules/redefine_largefile_top.ml index 883e8c7943..e436262dce 100644 --- a/testsuite/tests/typing-shadowing-of-pervasives-submodules/redefine_largefile_top.ml +++ b/testsuite/tests/typing-shadowing-of-pervasives-submodules/redefine_largefile_top.ml @@ -1,15 +1,15 @@ (* TEST - readonly_files = "largeFile.ml" - * setup-ocaml-build-env - ** ocamlc.byte - compile_only = "true" - all_modules = "largeFile.ml" - *** script - script = "mkdir -p inc" - **** script - script = "mv largeFile.cmi largeFile.cmo inc/" - ***** ocaml - ****** check-ocaml-output + readonly_files = "largeFile.ml"; + setup-ocaml-build-env; + compile_only = "true"; + all_modules = "largeFile.ml"; + ocamlc.byte; + script = "mkdir -p inc"; + script; + script = "mv largeFile.cmi largeFile.cmo inc/"; + script; + ocaml; + check-ocaml-output; *) #directory "inc";; #load "largeFile.cmo";; diff --git a/testsuite/tests/typing-short-paths/errors.ml b/testsuite/tests/typing-short-paths/errors.ml index 577c149930..948c36e2f6 100644 --- a/testsuite/tests/typing-short-paths/errors.ml +++ b/testsuite/tests/typing-short-paths/errors.ml @@ -1,6 +1,6 @@ (* TEST - flags = " -short-paths " - * expect + flags = " -short-paths "; + expect; *) module M = struct type t = T end diff --git a/testsuite/tests/typing-short-paths/gpr1223.ml b/testsuite/tests/typing-short-paths/gpr1223.ml index 9e66dfb90e..2a631f34e3 100644 --- a/testsuite/tests/typing-short-paths/gpr1223.ml +++ b/testsuite/tests/typing-short-paths/gpr1223.ml @@ -1,7 +1,7 @@ (* TEST - flags = " -short-paths " - modules = "gpr1223_foo.mli gpr1223_bar.mli" - * toplevel + flags = " -short-paths "; + modules = "gpr1223_foo.mli gpr1223_bar.mli"; + toplevel; *) let y = Gpr1223_bar.N.O.T;; diff --git a/testsuite/tests/typing-short-paths/pr5918.ml b/testsuite/tests/typing-short-paths/pr5918.ml index 191ee1fde0..4eac4e28a0 100644 --- a/testsuite/tests/typing-short-paths/pr5918.ml +++ b/testsuite/tests/typing-short-paths/pr5918.ml @@ -1,6 +1,6 @@ -(* TEST - flags = " -short-paths " - * toplevel +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + *) module rec A : sig @@ -10,3 +10,8 @@ end = struct let _ = { a = () } end ;; + +(* TEST + flags = " -short-paths "; + toplevel; +*) diff --git a/testsuite/tests/typing-short-paths/pr6836.ml b/testsuite/tests/typing-short-paths/pr6836.ml index ade6635b0c..93a8b3ee45 100644 --- a/testsuite/tests/typing-short-paths/pr6836.ml +++ b/testsuite/tests/typing-short-paths/pr6836.ml @@ -1,6 +1,6 @@ (* TEST - flags = " -short-paths " - * toplevel + flags = " -short-paths "; + toplevel; *) type t = [`A | `B];; diff --git a/testsuite/tests/typing-short-paths/pr7543.ml b/testsuite/tests/typing-short-paths/pr7543.ml index abe5d5306b..3dc33fb4c7 100644 --- a/testsuite/tests/typing-short-paths/pr7543.ml +++ b/testsuite/tests/typing-short-paths/pr7543.ml @@ -1,6 +1,6 @@ (* TEST - flags = " -short-paths " - * toplevel + flags = " -short-paths "; + toplevel; *) (** Test that short-path printtyp does not fail on packed module. diff --git a/testsuite/tests/typing-short-paths/short-paths.ml b/testsuite/tests/typing-short-paths/short-paths.ml index e6721af45f..c5c725ed43 100644 --- a/testsuite/tests/typing-short-paths/short-paths.ml +++ b/testsuite/tests/typing-short-paths/short-paths.ml @@ -1,6 +1,6 @@ (* TEST - flags = " -short-paths " - * toplevel + flags = " -short-paths "; + toplevel; *) module Core = struct diff --git a/testsuite/tests/typing-signatures/els.ml b/testsuite/tests/typing-signatures/els.ml index a438c735aa..429d68e4ca 100644 --- a/testsuite/tests/typing-signatures/els.ml +++ b/testsuite/tests/typing-signatures/els.ml @@ -1,5 +1,5 @@ (* TEST - * toplevel + toplevel; *) (* Adapted from: An Expressive Language of Signatures diff --git a/testsuite/tests/typing-signatures/nondep_regression.ml b/testsuite/tests/typing-signatures/nondep_regression.ml index 76033b3c4e..2e446b44e5 100644 --- a/testsuite/tests/typing-signatures/nondep_regression.ml +++ b/testsuite/tests/typing-signatures/nondep_regression.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) type 'a seq = 'a list diff --git a/testsuite/tests/typing-signatures/pr6371.ml b/testsuite/tests/typing-signatures/pr6371.ml index c5516c3f2f..d7b36fdc0b 100644 --- a/testsuite/tests/typing-signatures/pr6371.ml +++ b/testsuite/tests/typing-signatures/pr6371.ml @@ -1,5 +1,5 @@ (* TEST - * toplevel + toplevel; *) module M = struct diff --git a/testsuite/tests/typing-signatures/pr6672.ml b/testsuite/tests/typing-signatures/pr6672.ml index 66852161de..1a533e6ba6 100644 --- a/testsuite/tests/typing-signatures/pr6672.ml +++ b/testsuite/tests/typing-signatures/pr6672.ml @@ -1,5 +1,5 @@ (* TEST - * toplevel + toplevel; *) module type S = sig type 'a t end;; diff --git a/testsuite/tests/typing-sigsubst/sig_local_aliases.ml b/testsuite/tests/typing-sigsubst/sig_local_aliases.ml index 096312adfa..a13be7ae85 100644 --- a/testsuite/tests/typing-sigsubst/sig_local_aliases.ml +++ b/testsuite/tests/typing-sigsubst/sig_local_aliases.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module M = struct diff --git a/testsuite/tests/typing-sigsubst/sig_local_aliases_syntax_errors.ml b/testsuite/tests/typing-sigsubst/sig_local_aliases_syntax_errors.ml index b387ec6aee..b56f6eebc5 100644 --- a/testsuite/tests/typing-sigsubst/sig_local_aliases_syntax_errors.ml +++ b/testsuite/tests/typing-sigsubst/sig_local_aliases_syntax_errors.ml @@ -1,5 +1,5 @@ -(* TEST - * toplevel +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) *) module type Rejected1 = sig @@ -34,3 +34,7 @@ end;; module type Rejected0 = sig type nonrec t := int end;; + +(* TEST + toplevel; +*) diff --git a/testsuite/tests/typing-sigsubst/sigsubst.ml b/testsuite/tests/typing-sigsubst/sigsubst.ml index 1acad669c2..20f58f038e 100644 --- a/testsuite/tests/typing-sigsubst/sigsubst.ml +++ b/testsuite/tests/typing-sigsubst/sigsubst.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) module type Printable = sig diff --git a/testsuite/tests/typing-sigsubst/test_locations.ml b/testsuite/tests/typing-sigsubst/test_locations.ml index 4e727100f4..3ad1898195 100644 --- a/testsuite/tests/typing-sigsubst/test_locations.ml +++ b/testsuite/tests/typing-sigsubst/test_locations.ml @@ -1,26 +1,35 @@ (* TEST -readonly_files = "test_functor.ml test_loc_modtype_type_eq.ml \ - test_loc_modtype_type_subst.ml test_loc_type_eq.ml \ - test_loc_type_subst.ml mpr7852.mli" -* setup-ocamlc.byte-build-env -** ocamlc.byte -module = "test_functor.ml" -** ocamlc.byte -module = "test_loc_type_eq.ml" -ocamlc_byte_exit_status = "2" -** ocamlc.byte -module = "test_loc_modtype_type_eq.ml" -ocamlc_byte_exit_status = "2" -** ocamlc.byte -module = "test_loc_type_subst.ml" -ocamlc_byte_exit_status = "2" -** ocamlc.byte -module = "test_loc_modtype_type_subst.ml" -ocamlc_byte_exit_status = "2" -** check-ocamlc.byte-output -** ocamlc.byte -flags = "-w +32" -module = "mpr7852.mli" -ocamlc_byte_exit_status = "0" -** check-ocamlc.byte-output + readonly_files = "test_functor.ml test_loc_modtype_type_eq.ml \ + test_loc_modtype_type_subst.ml test_loc_type_eq.ml test_loc_type_subst.ml \ + mpr7852.mli"; + setup-ocamlc.byte-build-env; + { + module = "test_functor.ml"; + ocamlc.byte; + }{ + module = "test_loc_type_eq.ml"; + ocamlc_byte_exit_status = "2"; + ocamlc.byte; + }{ + module = "test_loc_modtype_type_eq.ml"; + ocamlc_byte_exit_status = "2"; + ocamlc.byte; + }{ + module = "test_loc_type_subst.ml"; + ocamlc_byte_exit_status = "2"; + ocamlc.byte; + }{ + module = "test_loc_modtype_type_subst.ml"; + ocamlc_byte_exit_status = "2"; + ocamlc.byte; + }{ + check-ocamlc.byte-output; + }{ + flags = "-w +32"; + module = "mpr7852.mli"; + ocamlc_byte_exit_status = "0"; + ocamlc.byte; + }{ + check-ocamlc.byte-output; + } *) diff --git a/testsuite/tests/typing-typeparam/newtype.ml b/testsuite/tests/typing-typeparam/newtype.ml index b41d0dfcf1..a372a12bdc 100644 --- a/testsuite/tests/typing-typeparam/newtype.ml +++ b/testsuite/tests/typing-typeparam/newtype.ml @@ -1,5 +1,5 @@ (* TEST - * toplevel + toplevel; *) let property (type t) () = diff --git a/testsuite/tests/typing-unboxed-types/test.ml b/testsuite/tests/typing-unboxed-types/test.ml index 5e81a3d75f..34e0035d9b 100644 --- a/testsuite/tests/typing-unboxed-types/test.ml +++ b/testsuite/tests/typing-unboxed-types/test.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (* Check the unboxing *) diff --git a/testsuite/tests/typing-unboxed-types/test_flat.ml b/testsuite/tests/typing-unboxed-types/test_flat.ml index 43791ed245..78b5c93d7c 100644 --- a/testsuite/tests/typing-unboxed-types/test_flat.ml +++ b/testsuite/tests/typing-unboxed-types/test_flat.ml @@ -1,6 +1,6 @@ (* TEST - * flat-float-array - ** expect + flat-float-array; + expect; *) (* should fail *) diff --git a/testsuite/tests/typing-unboxed-types/test_no_flat.ml b/testsuite/tests/typing-unboxed-types/test_no_flat.ml index a1c48d2c03..980c519c81 100644 --- a/testsuite/tests/typing-unboxed-types/test_no_flat.ml +++ b/testsuite/tests/typing-unboxed-types/test_no_flat.ml @@ -1,6 +1,6 @@ (* TEST - * no-flat-float-array - ** expect + no-flat-float-array; + expect; *) (* This file copies the tests from test_flat.ml, diff --git a/testsuite/tests/typing-unboxed/test.ml b/testsuite/tests/typing-unboxed/test.ml index a4ecd29120..8c29545f8b 100644 --- a/testsuite/tests/typing-unboxed/test.ml +++ b/testsuite/tests/typing-unboxed/test.ml @@ -1,6 +1,6 @@ (* TEST - flags = "-strict-sequence" - * expect + flags = "-strict-sequence"; + expect; *) external a : (int [@untagged]) -> unit = "a" "a_nat" external b : (int32 [@unboxed]) -> unit = "b" "b_nat" diff --git a/testsuite/tests/typing-warnings/ambiguous_guarded_disjunction.ml b/testsuite/tests/typing-warnings/ambiguous_guarded_disjunction.ml index cfaea68b87..eff6a73aec 100644 --- a/testsuite/tests/typing-warnings/ambiguous_guarded_disjunction.ml +++ b/testsuite/tests/typing-warnings/ambiguous_guarded_disjunction.ml @@ -1,6 +1,6 @@ (* TEST - flags = " -w +A -strict-sequence " - * expect + flags = " -w +A -strict-sequence "; + expect; *) (* Ignore OCAMLRUNPARAM=b to be reproducible *) diff --git a/testsuite/tests/typing-warnings/application.ml b/testsuite/tests/typing-warnings/application.ml index 8da9782112..8ad444b079 100644 --- a/testsuite/tests/typing-warnings/application.ml +++ b/testsuite/tests/typing-warnings/application.ml @@ -1,6 +1,6 @@ (* TEST - flags = " -w +A -strict-sequence " - * expect + flags = " -w +A -strict-sequence "; + expect; *) (* Ignore OCAMLRUNPARAM=b to be reproducible *) diff --git a/testsuite/tests/typing-warnings/coercions.ml b/testsuite/tests/typing-warnings/coercions.ml index 4c96caa4ed..874dd35d71 100644 --- a/testsuite/tests/typing-warnings/coercions.ml +++ b/testsuite/tests/typing-warnings/coercions.ml @@ -1,6 +1,6 @@ (* TEST - flags = " -w +A -strict-sequence " - * expect + flags = " -w +A -strict-sequence "; + expect; *) (* comment 9644 of PR#6000 *) diff --git a/testsuite/tests/typing-warnings/disable_warnings_classes.ml b/testsuite/tests/typing-warnings/disable_warnings_classes.ml index 79f1f4b686..cd502a9b1a 100644 --- a/testsuite/tests/typing-warnings/disable_warnings_classes.ml +++ b/testsuite/tests/typing-warnings/disable_warnings_classes.ml @@ -1,6 +1,6 @@ (* TEST - flags = " -w +A " - * expect + flags = " -w +A "; + expect; *) class c = object diff --git a/testsuite/tests/typing-warnings/exhaustiveness.ml b/testsuite/tests/typing-warnings/exhaustiveness.ml index 62add57930..702ab1e51c 100644 --- a/testsuite/tests/typing-warnings/exhaustiveness.ml +++ b/testsuite/tests/typing-warnings/exhaustiveness.ml @@ -1,6 +1,6 @@ (* TEST - flags = " -w +A -strict-sequence " - * expect + flags = " -w +A -strict-sequence "; + expect; *) let f = function diff --git a/testsuite/tests/typing-warnings/never_returns.ml b/testsuite/tests/typing-warnings/never_returns.ml index fac31d9dd3..b12b4da71a 100644 --- a/testsuite/tests/typing-warnings/never_returns.ml +++ b/testsuite/tests/typing-warnings/never_returns.ml @@ -1,6 +1,6 @@ (* TEST - flags = " -w -a+21 " - * expect + flags = " -w -a+21 "; + expect; *) let () = (let module L = List in raise Exit); () ;; diff --git a/testsuite/tests/typing-warnings/open_warnings.ml b/testsuite/tests/typing-warnings/open_warnings.ml index de810ae106..9e4f33817e 100644 --- a/testsuite/tests/typing-warnings/open_warnings.ml +++ b/testsuite/tests/typing-warnings/open_warnings.ml @@ -1,6 +1,6 @@ (* TEST - flags = " -w +A-41-42-18" - * expect + flags = " -w +A-41-42-18"; + expect; *) module T1 : sig end = struct module M = struct type t end (* unused type t *) diff --git a/testsuite/tests/typing-warnings/pr5892.ml b/testsuite/tests/typing-warnings/pr5892.ml index 08939c033f..c1cdd26d8b 100644 --- a/testsuite/tests/typing-warnings/pr5892.ml +++ b/testsuite/tests/typing-warnings/pr5892.ml @@ -1,6 +1,6 @@ (* TEST - flags = " -w +A -strict-sequence " - * expect + flags = " -w +A -strict-sequence "; + expect; *) open CamlinternalOO;; diff --git a/testsuite/tests/typing-warnings/pr6587.ml b/testsuite/tests/typing-warnings/pr6587.ml index 36b9044718..ba4b14ea1e 100644 --- a/testsuite/tests/typing-warnings/pr6587.ml +++ b/testsuite/tests/typing-warnings/pr6587.ml @@ -1,6 +1,6 @@ (* TEST - flags = " -w +A -strict-sequence " - * expect + flags = " -w +A -strict-sequence "; + expect; *) diff --git a/testsuite/tests/typing-warnings/pr6872.ml b/testsuite/tests/typing-warnings/pr6872.ml index 0fbf076da6..b3d8b803a9 100644 --- a/testsuite/tests/typing-warnings/pr6872.ml +++ b/testsuite/tests/typing-warnings/pr6872.ml @@ -1,6 +1,6 @@ (* TEST - flags = " -w +A -strict-sequence " - * expect + flags = " -w +A -strict-sequence "; + expect; *) (* Ignore OCAMLRUNPARAM=b to be reproducible *) diff --git a/testsuite/tests/typing-warnings/pr7085.ml b/testsuite/tests/typing-warnings/pr7085.ml index c286f154f2..25560ad82e 100644 --- a/testsuite/tests/typing-warnings/pr7085.ml +++ b/testsuite/tests/typing-warnings/pr7085.ml @@ -1,6 +1,6 @@ (* TEST - flags = " -w +A -strict-sequence " - * expect + flags = " -w +A -strict-sequence "; + expect; *) module TypEq = struct diff --git a/testsuite/tests/typing-warnings/pr7115.ml b/testsuite/tests/typing-warnings/pr7115.ml index c1e5bef11a..64b1b37735 100644 --- a/testsuite/tests/typing-warnings/pr7115.ml +++ b/testsuite/tests/typing-warnings/pr7115.ml @@ -1,6 +1,6 @@ (* TEST - flags = " -w +A -strict-sequence " - * expect + flags = " -w +A -strict-sequence "; + expect; *) type t = A : t;; diff --git a/testsuite/tests/typing-warnings/pr7261.ml b/testsuite/tests/typing-warnings/pr7261.ml index 65c44ecf17..f032cff317 100644 --- a/testsuite/tests/typing-warnings/pr7261.ml +++ b/testsuite/tests/typing-warnings/pr7261.ml @@ -1,9 +1,14 @@ -(* TEST - flags = " -w +A -strict-sequence " - * toplevel +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + *) type foo = Foo: [> `Bla ] as 'b ) * 'b -> foo;; type foo = Foo: 'b * 'b -> foo constraint 'b = [> `Bla ];; + +(* TEST + flags = " -w +A -strict-sequence "; + toplevel; +*) diff --git a/testsuite/tests/typing-warnings/pr7297.ml b/testsuite/tests/typing-warnings/pr7297.ml index 572bdb2c95..3d4d724463 100644 --- a/testsuite/tests/typing-warnings/pr7297.ml +++ b/testsuite/tests/typing-warnings/pr7297.ml @@ -1,6 +1,6 @@ (* TEST - flags = " -w +A -strict-sequence " - * expect + flags = " -w +A -strict-sequence "; + expect; *) (* Ignore OCAMLRUNPARAM=b to be reproducible *) diff --git a/testsuite/tests/typing-warnings/pr7553.ml b/testsuite/tests/typing-warnings/pr7553.ml index ef57b0ee7b..25defbed8b 100644 --- a/testsuite/tests/typing-warnings/pr7553.ml +++ b/testsuite/tests/typing-warnings/pr7553.ml @@ -1,6 +1,6 @@ (* TEST - flags = " -w +A -strict-sequence " - * expect + flags = " -w +A -strict-sequence "; + expect; *) module A = struct type foo end;; diff --git a/testsuite/tests/typing-warnings/pr9244.ml b/testsuite/tests/typing-warnings/pr9244.ml index 8fb319707e..282123cd33 100644 --- a/testsuite/tests/typing-warnings/pr9244.ml +++ b/testsuite/tests/typing-warnings/pr9244.ml @@ -1,6 +1,6 @@ (* TEST - flags = " -w +A " - * expect + flags = " -w +A "; + expect; *) module type U = sig end diff --git a/testsuite/tests/typing-warnings/records.ml b/testsuite/tests/typing-warnings/records.ml index 5079418d76..afb2e34bbe 100644 --- a/testsuite/tests/typing-warnings/records.ml +++ b/testsuite/tests/typing-warnings/records.ml @@ -1,6 +1,6 @@ (* TEST - flags = " -w +A -strict-sequence " - * expect + flags = " -w +A -strict-sequence "; + expect; *) (* Use type information *) diff --git a/testsuite/tests/typing-warnings/unused_functor_parameter.ml b/testsuite/tests/typing-warnings/unused_functor_parameter.ml index d14ec34aaa..a0905b0db8 100644 --- a/testsuite/tests/typing-warnings/unused_functor_parameter.ml +++ b/testsuite/tests/typing-warnings/unused_functor_parameter.ml @@ -1,6 +1,6 @@ (* TEST - flags = " -w +A " - * expect + flags = " -w +A "; + expect; *) module Foo(Unused : sig end) = struct end;; diff --git a/testsuite/tests/typing-warnings/unused_rec.ml b/testsuite/tests/typing-warnings/unused_rec.ml index 3f38f848aa..7e5bc66dc7 100644 --- a/testsuite/tests/typing-warnings/unused_rec.ml +++ b/testsuite/tests/typing-warnings/unused_rec.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) [@@@ocaml.warning "+39"] diff --git a/testsuite/tests/typing-warnings/unused_recmodule.ml b/testsuite/tests/typing-warnings/unused_recmodule.ml index 46c68e8a21..8ee636b538 100644 --- a/testsuite/tests/typing-warnings/unused_recmodule.ml +++ b/testsuite/tests/typing-warnings/unused_recmodule.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) [@@@ocaml.warning "+a"] diff --git a/testsuite/tests/typing-warnings/unused_types.ml b/testsuite/tests/typing-warnings/unused_types.ml index 66d18f1a57..c000d27bb1 100644 --- a/testsuite/tests/typing-warnings/unused_types.ml +++ b/testsuite/tests/typing-warnings/unused_types.ml @@ -1,6 +1,6 @@ (* TEST - flags = " -w +A -strict-sequence " - * expect + flags = " -w +A -strict-sequence "; + expect; *) module Unused : sig diff --git a/testsuite/tests/typing-warnings/warning16.ml b/testsuite/tests/typing-warnings/warning16.ml index a4ee983973..0cfa2974cc 100644 --- a/testsuite/tests/typing-warnings/warning16.ml +++ b/testsuite/tests/typing-warnings/warning16.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) let foo ?x = () [%%expect{| diff --git a/testsuite/tests/unboxed-primitive-args/test.ml b/testsuite/tests/unboxed-primitive-args/test.ml index b93120dd67..6490954a68 100644 --- a/testsuite/tests/unboxed-primitive-args/test.ml +++ b/testsuite/tests/unboxed-primitive-args/test.ml @@ -1,19 +1,16 @@ (* TEST - -readonly_files = "common.mli common.ml test_common.c test_common.h" - -* setup-ocamlopt.byte-build-env -** ocaml -test_file = "${test_source_directory}/gen_test.ml" -ocaml_script_as_argument = "true" -arguments = "c" -compiler_output = "stubs.c" -*** ocaml -arguments = "ml" -compiler_output = "main.ml" -**** ocamlopt.byte -all_modules = "test_common.c stubs.c common.mli common.ml main.ml" -***** run -****** check-program-output - + readonly_files = "common.mli common.ml test_common.c test_common.h"; + setup-ocamlopt.byte-build-env; + test_file = "${test_source_directory}/gen_test.ml"; + ocaml_script_as_argument = "true"; + arguments = "c"; + compiler_output = "stubs.c"; + ocaml; + arguments = "ml"; + compiler_output = "main.ml"; + ocaml; + all_modules = "test_common.c stubs.c common.mli common.ml main.ml"; + ocamlopt.byte; + run; + check-program-output; *) diff --git a/testsuite/tests/unwind/driver.ml b/testsuite/tests/unwind/driver.ml index 7df39daf0e..d56bef4339 100644 --- a/testsuite/tests/unwind/driver.ml +++ b/testsuite/tests/unwind/driver.ml @@ -1,26 +1,23 @@ (* TEST - -script = "sh ${test_source_directory}/check-linker-version.sh" -readonly_files = "mylib.mli mylib.ml stack_walker.c" - -* macos -** script -*** setup-ocamlopt.byte-build-env -**** ocamlopt.byte -flags = "-opaque" -module = "mylib.mli" -***** ocamlopt.byte -module = "" -flags = "-cclib -Wl,-keep_dwarf_unwind" -all_modules = "mylib.ml driver.ml stack_walker.c" -program = "${test_build_directory}/unwind_test" -****** run -output = "${test_build_directory}/program-output" -stdout = "${output}" -stderr = "${output}" -******* check-program-output -reference = "${test_source_directory}/unwind_test.reference" - + script = "sh ${test_source_directory}/check-linker-version.sh"; + readonly_files = "mylib.mli mylib.ml stack_walker.c"; + macos; + script; + setup-ocamlopt.byte-build-env; + flags = "-opaque"; + module = "mylib.mli"; + ocamlopt.byte; + module = ""; + flags = "-cclib -Wl,-keep_dwarf_unwind"; + all_modules = "mylib.ml driver.ml stack_walker.c"; + program = "${test_build_directory}/unwind_test"; + ocamlopt.byte; + output = "${test_build_directory}/program-output"; + stdout = "${output}"; + stderr = "${output}"; + run; + reference = "${test_source_directory}/unwind_test.reference"; + check-program-output; *) let () = diff --git a/testsuite/tests/utils/edit_distance.ml b/testsuite/tests/utils/edit_distance.ml index 1ac1070136..cf2e60cba9 100644 --- a/testsuite/tests/utils/edit_distance.ml +++ b/testsuite/tests/utils/edit_distance.ml @@ -1,8 +1,8 @@ (* TEST -include config -include testing -binary_modules = "config build_path_prefix_map misc identifiable numbers" -* bytecode + include config; + include testing; + binary_modules = "config build_path_prefix_map misc identifiable numbers"; + bytecode; *) let edit_distance = Misc.edit_distance diff --git a/testsuite/tests/utils/find_first_mono.ml b/testsuite/tests/utils/find_first_mono.ml index 80ea5e6255..1970eb9e40 100644 --- a/testsuite/tests/utils/find_first_mono.ml +++ b/testsuite/tests/utils/find_first_mono.ml @@ -1,8 +1,8 @@ (* TEST -include config -include testing -binary_modules = "config build_path_prefix_map misc" -* bytecode + include config; + include testing; + binary_modules = "config build_path_prefix_map misc"; + bytecode; *) let check_and_count_calls n = diff --git a/testsuite/tests/utils/magic_number.ml b/testsuite/tests/utils/magic_number.ml index a443e253e5..42664ec80b 100644 --- a/testsuite/tests/utils/magic_number.ml +++ b/testsuite/tests/utils/magic_number.ml @@ -1,7 +1,7 @@ (* TEST -include config -binary_modules = "config build_path_prefix_map misc" -* bytecode + include config; + binary_modules = "config build_path_prefix_map misc"; + bytecode; *) open Misc diff --git a/testsuite/tests/utils/overflow_detection.ml b/testsuite/tests/utils/overflow_detection.ml index 11f3aafaeb..c9d984b55b 100644 --- a/testsuite/tests/utils/overflow_detection.ml +++ b/testsuite/tests/utils/overflow_detection.ml @@ -1,8 +1,8 @@ (* TEST -include config -include testing -binary_modules = "config build_path_prefix_map misc identifiable numbers" -* bytecode + include config; + include testing; + binary_modules = "config build_path_prefix_map misc identifiable numbers"; + bytecode; *) let print_int i = diff --git a/testsuite/tests/utils/test_strongly_connected_components.ml b/testsuite/tests/utils/test_strongly_connected_components.ml index 05845228b5..32cdc6bb25 100644 --- a/testsuite/tests/utils/test_strongly_connected_components.ml +++ b/testsuite/tests/utils/test_strongly_connected_components.ml @@ -1,10 +1,8 @@ (* TEST -include config -include testing -binary_modules = - "config build_path_prefix_map misc identifiable numbers \ - strongly_connected_components" -* bytecode + include config; + include testing; + binary_modules = "config build_path_prefix_map misc identifiable numbers strongly_connected_components"; + bytecode; *) module Int = Numbers.Int diff --git a/testsuite/tests/warnings/deprecated_module.ml b/testsuite/tests/warnings/deprecated_module.ml index 178483d728..a8ec2c4aef 100644 --- a/testsuite/tests/warnings/deprecated_module.ml +++ b/testsuite/tests/warnings/deprecated_module.ml @@ -1,8 +1,8 @@ -(* TEST +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + -flags = "-w +A" -* bytecode *) @@ -15,3 +15,8 @@ end let _ = M.x include M + +(* TEST + flags = "-w +A"; + bytecode; +*) diff --git a/testsuite/tests/warnings/deprecated_module_assigment.ml b/testsuite/tests/warnings/deprecated_module_assigment.ml index c4f9b2b676..68ccd43b95 100644 --- a/testsuite/tests/warnings/deprecated_module_assigment.ml +++ b/testsuite/tests/warnings/deprecated_module_assigment.ml @@ -1,8 +1,8 @@ -(* TEST +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + -flags = "-w +A-70" -* bytecode *) @@ -84,3 +84,8 @@ struct module M = struct end [@@deprecated "FOO"] end module MD_OK : sig module M : sig end [@@deprecated] end = struct module M = struct end [@@deprecated "FOO"] end + +(* TEST + flags = "-w +A-70"; + bytecode; +*) diff --git a/testsuite/tests/warnings/deprecated_module_use.ml b/testsuite/tests/warnings/deprecated_module_use.ml index ca582ee1f6..b6a568ad0f 100644 --- a/testsuite/tests/warnings/deprecated_module_use.ml +++ b/testsuite/tests/warnings/deprecated_module_use.ml @@ -1,17 +1,17 @@ -(* TEST +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + + + + + + + -modules = "deprecated_module.mli deprecated_module.ml" -* setup-ocamlc.byte-build-env -** ocamlc.byte -flags = "-w -a" -module = "deprecated_module.mli" -*** ocamlc.byte -module = "deprecated_module.ml" -**** ocamlc.byte -flags = "-w +A-70" -module = "deprecated_module_use.ml" -***** check-ocamlc.byte-output *) @@ -21,3 +21,17 @@ type s = M.t open M let _ = x + +(* TEST + modules = "deprecated_module.mli deprecated_module.ml"; + setup-ocamlc.byte-build-env; + flags = "-w -a"; + module = "deprecated_module.mli"; + ocamlc.byte; + module = "deprecated_module.ml"; + ocamlc.byte; + flags = "-w +A-70"; + module = "deprecated_module_use.ml"; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/warnings/deprecated_mutable.ml b/testsuite/tests/warnings/deprecated_mutable.ml index 78fb12ac41..82ea7ec00b 100644 --- a/testsuite/tests/warnings/deprecated_mutable.ml +++ b/testsuite/tests/warnings/deprecated_mutable.ml @@ -1,8 +1,8 @@ -(* TEST +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + -flags = "-w +A-70" -* bytecode *) @@ -11,3 +11,8 @@ type t = {mutable x : int [@deprecated_mutable]} let y : t = {x = 5} let () = y.x <- 42 + +(* TEST + flags = "-w +A-70"; + bytecode; +*) diff --git a/testsuite/tests/warnings/deprecated_warning_specs.ml b/testsuite/tests/warnings/deprecated_warning_specs.ml index ac41e084c1..903b4757c4 100644 --- a/testsuite/tests/warnings/deprecated_warning_specs.ml +++ b/testsuite/tests/warnings/deprecated_warning_specs.ml @@ -1,5 +1,5 @@ (* TEST - * expect + expect; *) (** Deprecated sequences of unsigned letters *) diff --git a/testsuite/tests/warnings/mnemonics.mll b/testsuite/tests/warnings/mnemonics.mll index d1225ed0e3..3c6050b312 100644 --- a/testsuite/tests/warnings/mnemonics.mll +++ b/testsuite/tests/warnings/mnemonics.mll @@ -1,7 +1,5 @@ (* TEST - -ocamllex_flags = "-q" - + ocamllex_flags = "-q"; *) { diff --git a/testsuite/tests/warnings/w01.ml b/testsuite/tests/warnings/w01.ml index e72ec1901d..d78b2b5477 100644 --- a/testsuite/tests/warnings/w01.ml +++ b/testsuite/tests/warnings/w01.ml @@ -1,11 +1,11 @@ -(* TEST +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + -flags = "-w +A-70" -* setup-ocamlc.byte-build-env -** ocamlc.byte -compile_only = "true" -*** check-ocamlc.byte-output *) @@ -52,3 +52,11 @@ match 1 with (* X *) (* re-re *) + +(* TEST + flags = "-w +A-70"; + setup-ocamlc.byte-build-env; + compile_only = "true"; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/warnings/w03.ml b/testsuite/tests/warnings/w03.ml index d0a581220a..ff5aee7db1 100644 --- a/testsuite/tests/warnings/w03.ml +++ b/testsuite/tests/warnings/w03.ml @@ -1,11 +1,11 @@ -(* TEST +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + -flags = "-w +A-70" -* setup-ocamlc.byte-build-env -** ocamlc.byte -compile_only = "true" -*** check-ocamlc.byte-output *) @@ -22,3 +22,11 @@ let _ = B exception C [@deprecated] let _ = B [@warning "-53"] + +(* TEST + flags = "-w +A-70"; + setup-ocamlc.byte-build-env; + compile_only = "true"; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/warnings/w04.ml b/testsuite/tests/warnings/w04.ml index 21a09f52da..b2ddf4c935 100644 --- a/testsuite/tests/warnings/w04.ml +++ b/testsuite/tests/warnings/w04.ml @@ -1,11 +1,11 @@ -(* TEST +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + -flags = "-w +A-70" -* setup-ocamlc.byte-build-env -** ocamlc.byte -compile_only = "true" -*** check-ocamlc.byte-output *) @@ -21,3 +21,11 @@ type t = A | B let g x = match x with | A -> 0 | _ -> 1 + +(* TEST + flags = "-w +A-70"; + setup-ocamlc.byte-build-env; + compile_only = "true"; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/warnings/w04_failure.ml b/testsuite/tests/warnings/w04_failure.ml index 0ce23ca0ae..60462390c3 100644 --- a/testsuite/tests/warnings/w04_failure.ml +++ b/testsuite/tests/warnings/w04_failure.ml @@ -1,11 +1,11 @@ -(* TEST +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + -flags = "-w +A-70" -* setup-ocamlc.byte-build-env -** ocamlc.byte -compile_only = "true" -*** check-ocamlc.byte-output *) @@ -37,3 +37,11 @@ let silent_fragile2 (type t) (r1 : t repr) (r2 : t repr) (t : t) = | _, XY, X -> () | AB, _, _ -> () | _, XY, _ -> () + +(* TEST + flags = "-w +A-70"; + setup-ocamlc.byte-build-env; + compile_only = "true"; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/warnings/w06.ml b/testsuite/tests/warnings/w06.ml index dc4e6e6a6a..94bf0486de 100644 --- a/testsuite/tests/warnings/w06.ml +++ b/testsuite/tests/warnings/w06.ml @@ -1,11 +1,11 @@ -(* TEST +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + -flags = "-w +A-70" -* setup-ocamlc.byte-build-env -** ocamlc.byte -compile_only = "true" -*** check-ocamlc.byte-output *) @@ -15,3 +15,11 @@ let bar ~foo ~baz = ignore (foo, baz) (* two labels *) let () = foo 2 let () = bar 4 2 + +(* TEST + flags = "-w +A-70"; + setup-ocamlc.byte-build-env; + compile_only = "true"; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/warnings/w32.ml b/testsuite/tests/warnings/w32.ml index 1a8e7b7a1d..cbb1630e61 100644 --- a/testsuite/tests/warnings/w32.ml +++ b/testsuite/tests/warnings/w32.ml @@ -1,13 +1,13 @@ -(* TEST +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + + + -flags = "-w +A" -* setup-ocamlc.byte-build-env -** ocamlc.byte -module = "w32.mli" -*** ocamlc.byte -module = "w32.ml" -**** check-ocamlc.byte-output *) @@ -69,3 +69,13 @@ module H (X : sig val x : int end) = X module type S = sig module F: sig val x : int end -> sig end end + +(* TEST + flags = "-w +A"; + setup-ocamlc.byte-build-env; + module = "w32.mli"; + ocamlc.byte; + module = "w32.ml"; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/warnings/w32b.ml b/testsuite/tests/warnings/w32b.ml index bcb2fc2588..70f1b861b3 100644 --- a/testsuite/tests/warnings/w32b.ml +++ b/testsuite/tests/warnings/w32b.ml @@ -1,13 +1,21 @@ -(* TEST +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + -flags = "-w +A-70" -* setup-ocamlc.byte-build-env -** ocamlc.byte -compile_only = "true" -*** check-ocamlc.byte-output *) (* Check that [t] is considered unused without an .mli file (see GPR#1358) *) module Q (M : sig type t end) = struct end + +(* TEST + flags = "-w +A-70"; + setup-ocamlc.byte-build-env; + compile_only = "true"; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/warnings/w33.ml b/testsuite/tests/warnings/w33.ml index 4c4abfd666..34635c8d39 100644 --- a/testsuite/tests/warnings/w33.ml +++ b/testsuite/tests/warnings/w33.ml @@ -1,11 +1,11 @@ -(* TEST +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + -flags = "-w +A-70" -* setup-ocamlc.byte-build-env -** ocamlc.byte -compile_only = "true" -*** check-ocamlc.byte-output *) @@ -25,3 +25,11 @@ let i (A|B) = B open! M (* useless open! *) open M (* useless open *) + +(* TEST + flags = "-w +A-70"; + setup-ocamlc.byte-build-env; + compile_only = "true"; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/warnings/w45.ml b/testsuite/tests/warnings/w45.ml index 01af3e796e..9091842c7f 100644 --- a/testsuite/tests/warnings/w45.ml +++ b/testsuite/tests/warnings/w45.ml @@ -1,11 +1,11 @@ -(* TEST +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + -flags = "-w +A-70" -* setup-ocamlc.byte-build-env -** ocamlc.byte -compile_only = "true" -*** check-ocamlc.byte-output *) @@ -25,3 +25,11 @@ module T3 = struct let _ = (A, X) (* X belongs to several types *) end + +(* TEST + flags = "-w +A-70"; + setup-ocamlc.byte-build-env; + compile_only = "true"; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/warnings/w47_inline.ml b/testsuite/tests/warnings/w47_inline.ml index fcdaedc475..30c7cc7101 100644 --- a/testsuite/tests/warnings/w47_inline.ml +++ b/testsuite/tests/warnings/w47_inline.ml @@ -1,11 +1,11 @@ -(* TEST +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + -flags = "-w +A-70" -* setup-ocamlc.byte-build-env -** ocamlc.byte -compile_only = "true" -*** check-ocamlc.byte-output *) @@ -39,3 +39,11 @@ let test x = else f5 x in f4 (f6 r) + +(* TEST + flags = "-w +A-70"; + setup-ocamlc.byte-build-env; + compile_only = "true"; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/warnings/w50.ml b/testsuite/tests/warnings/w50.ml index b6e868f89a..a9a1a92329 100644 --- a/testsuite/tests/warnings/w50.ml +++ b/testsuite/tests/warnings/w50.ml @@ -1,11 +1,11 @@ -(* TEST +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + -flags = "-w +A-70" -* setup-ocamlc.byte-build-env -** ocamlc.byte -compile_only = "true" -*** check-ocamlc.byte-output *) @@ -16,3 +16,11 @@ module A : sig end = struct module Y1 = X1 end + +(* TEST + flags = "-w +A-70"; + setup-ocamlc.byte-build-env; + compile_only = "true"; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/warnings/w51.ml b/testsuite/tests/warnings/w51.ml index abfee541f4..a471ccffcd 100644 --- a/testsuite/tests/warnings/w51.ml +++ b/testsuite/tests/warnings/w51.ml @@ -1,6 +1,6 @@ (* TEST - flags = "-w +A-70" - * expect + flags = "-w +A-70"; + expect; *) let rec fact = function diff --git a/testsuite/tests/warnings/w51_bis.ml b/testsuite/tests/warnings/w51_bis.ml index bb5bcaac1a..660210627c 100644 --- a/testsuite/tests/warnings/w51_bis.ml +++ b/testsuite/tests/warnings/w51_bis.ml @@ -1,11 +1,11 @@ -(* TEST +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + -flags = "-w +A-70" -* setup-ocamlc.byte-build-env -** ocamlc.byte -compile_only = "true" -*** check-ocamlc.byte-output *) @@ -14,3 +14,11 @@ let rec foldl op acc = function | x :: xs -> try (foldl [@tailcall]) op (op x acc) xs with Not_found -> assert false + +(* TEST + flags = "-w +A-70"; + setup-ocamlc.byte-build-env; + compile_only = "true"; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/warnings/w52.ml b/testsuite/tests/warnings/w52.ml index 55204e8cd8..c444c1a458 100644 --- a/testsuite/tests/warnings/w52.ml +++ b/testsuite/tests/warnings/w52.ml @@ -1,6 +1,6 @@ (* TEST - flags = "-w +A" - * expect + flags = "-w +A"; + expect; *) let () = try () with Invalid_argument "Any" -> ();; diff --git a/testsuite/tests/warnings/w53.ml b/testsuite/tests/warnings/w53.ml index 4a31ed446e..545fec18b1 100644 --- a/testsuite/tests/warnings/w53.ml +++ b/testsuite/tests/warnings/w53.ml @@ -1,11 +1,11 @@ -(* TEST +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + -flags = "-w +A-60-70" -* setup-ocamlc.byte-build-env -** ocamlc.byte -compile_only = "true" -*** check-ocamlc.byte-output *) @@ -47,3 +47,11 @@ module I' = Set.Make [@ocaml.inlined] module J = Set.Make [@@inlined] module J' = Set.Make [@@ocaml.inlined] + +(* TEST + flags = "-w +A-60-70"; + setup-ocamlc.byte-build-env; + compile_only = "true"; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/warnings/w54.ml b/testsuite/tests/warnings/w54.ml index e9f29cb3e2..80f3b2604c 100644 --- a/testsuite/tests/warnings/w54.ml +++ b/testsuite/tests/warnings/w54.ml @@ -1,11 +1,11 @@ -(* TEST +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + -flags = "-w +A-70" -* setup-ocamlc.byte-build-env -** ocamlc.byte -compile_only = "true" -*** check-ocamlc.byte-output *) @@ -17,3 +17,11 @@ let h x = (g [@inlined] [@ocaml.inlined never]) x let v = ((fun x -> x) [@inline] [@inlined]) 1 (* accepted *) let i = ((fun x -> x) [@inline]) [@@inline] + +(* TEST + flags = "-w +A-70"; + setup-ocamlc.byte-build-env; + compile_only = "true"; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/warnings/w55.ml b/testsuite/tests/warnings/w55.ml index d597d46687..9654a0c3e2 100644 --- a/testsuite/tests/warnings/w55.ml +++ b/testsuite/tests/warnings/w55.ml @@ -1,22 +1,22 @@ -(* TEST +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + + + + + + + + + + -flags = "-w +A-70" -compile_only = "true" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output -* no-flambda -** setup-ocamlopt.byte-build-env -*** ocamlopt.byte -**** check-ocamlopt.byte-output -* flambda -compiler_reference = "${test_source_directory}/w55.flambda.reference" -** setup-ocamlopt.byte-build-env -*** ocamlopt.byte -**** check-ocamlopt.byte-output *) @@ -50,3 +50,24 @@ let h' x = (j [@inlined hint]) x let b' x y = (a [@inlined hint]) x y let d' x = (c [@inlined hint]) x + +(* TEST + flags = "-w +A-70"; + compile_only = "true"; + { + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; + }{ + no-flambda; + setup-ocamlopt.byte-build-env; + ocamlopt.byte; + check-ocamlopt.byte-output; + }{ + compiler_reference = "${test_source_directory}/w55.flambda.reference"; + flambda; + setup-ocamlopt.byte-build-env; + ocamlopt.byte; + check-ocamlopt.byte-output; + } +*) diff --git a/testsuite/tests/warnings/w58.ml b/testsuite/tests/warnings/w58.ml index cb8ab6194e..401ddf12c8 100644 --- a/testsuite/tests/warnings/w58.ml +++ b/testsuite/tests/warnings/w58.ml @@ -1,22 +1,21 @@ (* TEST - -flags = "-w +A-70" -readonly_files = "module_without_cmx.mli" - -* setup-ocamlc.byte-build-env -** ocamlc.byte -module = "module_without_cmx.mli" -*** ocamlc.byte -module = "w58.ml" -**** check-ocamlc.byte-output - -* setup-ocamlopt.byte-build-env -** ocamlopt.byte -module = "module_without_cmx.mli" -*** ocamlopt.byte -module = "w58.ml" -**** check-ocamlopt.byte-output - + flags = "-w +A-70"; + readonly_files = "module_without_cmx.mli"; + { + setup-ocamlc.byte-build-env; + module = "module_without_cmx.mli"; + ocamlc.byte; + module = "w58.ml"; + ocamlc.byte; + check-ocamlc.byte-output; + }{ + setup-ocamlopt.byte-build-env; + module = "module_without_cmx.mli"; + ocamlopt.byte; + module = "w58.ml"; + ocamlopt.byte; + check-ocamlopt.byte-output; + } *) let () = print_endline (Module_without_cmx.id "Hello World") diff --git a/testsuite/tests/warnings/w59.ml b/testsuite/tests/warnings/w59.ml index 64d4c76fa1..9d8cd4cec8 100644 --- a/testsuite/tests/warnings/w59.ml +++ b/testsuite/tests/warnings/w59.ml @@ -1,23 +1,23 @@ -(* TEST +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + + + + + + + + + + + -flags = "-w +A-70" -compile_only = "true" -* setup-ocamlc.byte-build-env -** ocamlc.byte -*** check-ocamlc.byte-output -* no-flambda -** setup-ocamlopt.byte-build-env -*** ocamlopt.byte -**** check-ocamlopt.byte-output -* flambda -compiler_reference = "${test_source_directory}/w59.flambda.reference" -flags = "-w +A-70 -dflambda-invariants" -** setup-ocamlopt.byte-build-env -*** ocamlopt.byte -**** check-ocamlopt.byte-output *) @@ -64,3 +64,25 @@ let set_opaque = (Obj.repr opaque) 0 (Obj.repr 3) + +(* TEST + flags = "-w +A-70"; + compile_only = "true"; + { + setup-ocamlc.byte-build-env; + ocamlc.byte; + check-ocamlc.byte-output; + }{ + no-flambda; + setup-ocamlopt.byte-build-env; + ocamlopt.byte; + check-ocamlopt.byte-output; + }{ + compiler_reference = "${test_source_directory}/w59.flambda.reference"; + flags = "-w +A-70 -dflambda-invariants"; + flambda; + setup-ocamlopt.byte-build-env; + ocamlopt.byte; + check-ocamlopt.byte-output; + } +*) diff --git a/testsuite/tests/warnings/w60.ml b/testsuite/tests/warnings/w60.ml index aeab53db9d..7081bea80c 100644 --- a/testsuite/tests/warnings/w60.ml +++ b/testsuite/tests/warnings/w60.ml @@ -1,11 +1,11 @@ -(* TEST +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + -flags = "-w +A-67" -* setup-ocamlc.byte-build-env -** ocamlc.byte -compile_only = "true" -*** check-ocamlc.byte-output *) @@ -39,3 +39,11 @@ let () = (* M is unused, but no warning was emitted before 4.10. *) let module M = struct end in () + +(* TEST + flags = "-w +A-67"; + setup-ocamlc.byte-build-env; + compile_only = "true"; + ocamlc.byte; + check-ocamlc.byte-output; +*) diff --git a/testsuite/tests/warnings/w68.ml b/testsuite/tests/warnings/w68.ml index 4fe03ef788..ffd98ed0f4 100644 --- a/testsuite/tests/warnings/w68.ml +++ b/testsuite/tests/warnings/w68.ml @@ -1,12 +1,12 @@ -(* TEST +(* TEST_BELOW +(* Blank lines added here to preserve locations. *) + + + + + -flags = "-w +A-70" -* setup-ocamlopt.byte-build-env -** ocamlopt.byte -*** check-ocamlopt.byte-output -**** run -***** check-program-output *) type a = { mutable a : int } @@ -32,3 +32,12 @@ let () = let dont_warn_with_partial_match None x = x + +(* TEST + flags = "-w +A-70"; + setup-ocamlopt.byte-build-env; + ocamlopt.byte; + check-ocamlopt.byte-output; + run; + check-program-output; +*) diff --git a/testsuite/tests/weak-ephe-final/ephetest.ml b/testsuite/tests/weak-ephe-final/ephetest.ml index 2835ab8b7a..c246d647ef 100644 --- a/testsuite/tests/weak-ephe-final/ephetest.ml +++ b/testsuite/tests/weak-ephe-final/ephetest.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) let debug = false diff --git a/testsuite/tests/weak-ephe-final/ephetest2.ml b/testsuite/tests/weak-ephe-final/ephetest2.ml index 03e354f815..aa3f3e28a4 100644 --- a/testsuite/tests/weak-ephe-final/ephetest2.ml +++ b/testsuite/tests/weak-ephe-final/ephetest2.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) (*** This test evaluate boolean formula composed by conjunction and diff --git a/testsuite/tests/weak-ephe-final/ephetest3.ml b/testsuite/tests/weak-ephe-final/ephetest3.ml index 541910c91a..012563c5e6 100644 --- a/testsuite/tests/weak-ephe-final/ephetest3.ml +++ b/testsuite/tests/weak-ephe-final/ephetest3.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) (** This test weak table by application to the memoization of collatz (also known as syracuse) algorithm suite computation *) diff --git a/testsuite/tests/weak-ephe-final/finaliser.ml b/testsuite/tests/weak-ephe-final/finaliser.ml index 68cb7b2662..b4e63794e4 100644 --- a/testsuite/tests/weak-ephe-final/finaliser.ml +++ b/testsuite/tests/weak-ephe-final/finaliser.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) let m = 1000 let m' = 100 diff --git a/testsuite/tests/weak-ephe-final/pr12001.ml b/testsuite/tests/weak-ephe-final/pr12001.ml index e17c31bcf8..6d0c784404 100644 --- a/testsuite/tests/weak-ephe-final/pr12001.ml +++ b/testsuite/tests/weak-ephe-final/pr12001.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) let [@inline never] foo () = let s = "Hello" ^ " world!" in diff --git a/testsuite/tests/weak-ephe-final/weaklifetime.ml b/testsuite/tests/weak-ephe-final/weaklifetime.ml index 233d986dfa..678850d1dc 100644 --- a/testsuite/tests/weak-ephe-final/weaklifetime.ml +++ b/testsuite/tests/weak-ephe-final/weaklifetime.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) let () = Random.init 12345 diff --git a/testsuite/tests/weak-ephe-final/weaklifetime2.ml b/testsuite/tests/weak-ephe-final/weaklifetime2.ml index 2c75b00bfe..8c27aa6750 100644 --- a/testsuite/tests/weak-ephe-final/weaklifetime2.ml +++ b/testsuite/tests/weak-ephe-final/weaklifetime2.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) let n = 500 let loop = 2 diff --git a/testsuite/tests/weak-ephe-final/weaktest.ml b/testsuite/tests/weak-ephe-final/weaktest.ml index 5b66088722..464944a960 100644 --- a/testsuite/tests/weak-ephe-final/weaktest.ml +++ b/testsuite/tests/weak-ephe-final/weaktest.ml @@ -1,5 +1,4 @@ -(* TEST -*) +(* TEST *) let debug = false;; diff --git a/testsuite/tests/win-unicode/mltest.ml b/testsuite/tests/win-unicode/mltest.ml index f4760967bb..0ea18c6232 100644 --- a/testsuite/tests/win-unicode/mltest.ml +++ b/testsuite/tests/win-unicode/mltest.ml @@ -1,8 +1,8 @@ (* TEST -include unix -flags += "-strict-sequence -w +A -warn-error +A" -* windows-unicode -** toplevel + include unix; + flags += "-strict-sequence -w +A -warn-error +A"; + windows-unicode; + toplevel; *) let foreign_names = |