summaryrefslogtreecommitdiff
path: root/testsuite/tests/ghci/T18262/all.T
diff options
context:
space:
mode:
authorXavier Denis <xldenis@gmail.com>2020-06-15 11:37:16 +0200
committerMarge Bot <ben+marge-bot@smart-cactus.org>2020-06-23 22:48:56 -0400
commita2a9006b068ba9af9d41711307a8d597d2bb03d7 (patch)
tree1db6f5afc2eac3ceac844c6a9613be3990911a26 /testsuite/tests/ghci/T18262/all.T
parentcad62ef11972490b180fad3cd4a5c7754fa218e4 (diff)
downloadhaskell-a2a9006b068ba9af9d41711307a8d597d2bb03d7.tar.gz
Fix issue #18262 by zonking constraints after solving
Zonk residual constraints in checkForExistence to reveal user type errors. Previously when `:instances` was used with instances that have TypeError constraints the result would look something like: instance [safe] s0 => Err 'A -- Defined at ../Bug2.hs:8:10 whereas after zonking, `:instances` now sees the `TypeError` and properly eliminates the constraint from the results.
Diffstat (limited to 'testsuite/tests/ghci/T18262/all.T')
-rw-r--r--testsuite/tests/ghci/T18262/all.T1
1 files changed, 1 insertions, 0 deletions
diff --git a/testsuite/tests/ghci/T18262/all.T b/testsuite/tests/ghci/T18262/all.T
new file mode 100644
index 0000000000..fe8e28fe6d
--- /dev/null
+++ b/testsuite/tests/ghci/T18262/all.T
@@ -0,0 +1 @@
+test('T18262', [extra_files(['T18262.hs'])], ghci_script, ['T18262.script'])