summaryrefslogtreecommitdiff
path: root/testsuite/tests/ghci/T21390/all.T
diff options
context:
space:
mode:
Diffstat (limited to 'testsuite/tests/ghci/T21390/all.T')
-rw-r--r--testsuite/tests/ghci/T21390/all.T14
1 files changed, 14 insertions, 0 deletions
diff --git a/testsuite/tests/ghci/T21390/all.T b/testsuite/tests/ghci/T21390/all.T
new file mode 100644
index 0000000000..9f62cc8715
--- /dev/null
+++ b/testsuite/tests/ghci/T21390/all.T
@@ -0,0 +1,14 @@
+# This tests #21390, where data constructors constructed by the interpreter
+# would contain untagged values in strict fields.
+#
+# The test is structured as follows:
+#
+# * `Lib.hs` defines a type defining `Ty`, a type with a strict Maybe field;
+# this should be compiled to object code
+# * `GetTy.hs` defines a function, `getTy`, which scrutinizes a `Ty` value and
+# its field. This too should be compiled to object code.
+# * `Test.hs` defines `mkTy` which constructs a `Ty`. This should be
+# interpreted.
+
+test('T21390', extra_files(['Lib.hs', 'Test.hs', 'GetTy.hs']), ghci_script, ['T21390.script'])
+