diff options
author | Gabriel Scherer <gabriel.scherer@gmail.com> | 2023-04-01 16:00:28 +0200 |
---|---|---|
committer | Gabriel Scherer <gabriel.scherer@gmail.com> | 2023-04-01 22:41:12 +0200 |
commit | 85929b2350f01a2a4c1110b43cf02e6da07cfb89 (patch) | |
tree | 1b821696adf42da5de195eb7326b9a26f57af108 /testsuite | |
parent | be27ba829f5eafb6abf9e5d91a78ea5403d52782 (diff) | |
download | ocaml-85929b2350f01a2a4c1110b43cf02e6da07cfb89.tar.gz |
caml_update_dummy: do not try to update size-0 atoms
fixes #12153
Suggested-by: Xavier Leroy <xavier.leroy@college-de-france.fr>
Suggested-by: Vincent Laviron <vincent.laviron@gmail.com>
Reported-by: Nick Roberts <nroberts@janestreet.com>
Diffstat (limited to 'testsuite')
-rw-r--r-- | testsuite/tests/letrec-compilation/pr12153_miscompilation_of_recursive_atoms.ml | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/testsuite/tests/letrec-compilation/pr12153_miscompilation_of_recursive_atoms.ml b/testsuite/tests/letrec-compilation/pr12153_miscompilation_of_recursive_atoms.ml new file mode 100644 index 0000000000..10ca5d6ea4 --- /dev/null +++ b/testsuite/tests/letrec-compilation/pr12153_miscompilation_of_recursive_atoms.ml @@ -0,0 +1,11 @@ +(* TEST *) + +let rec empty_int_array : int array = + let _ = empty_int_array in [||] + +let rec empty_float_array : float array = + let _ = empty_float_array in [||] + +module type Empty = sig end +let rec empty_mod : (module Empty) = + let _ = empty_mod in (module struct end) |