diff options
Diffstat (limited to 'testsuite/tests/th')
-rw-r--r-- | testsuite/tests/th/T16666.hs | 11 | ||||
-rw-r--r-- | testsuite/tests/th/T16666.stderr | 7 | ||||
-rw-r--r-- | testsuite/tests/th/all.T | 1 |
3 files changed, 19 insertions, 0 deletions
diff --git a/testsuite/tests/th/T16666.hs b/testsuite/tests/th/T16666.hs new file mode 100644 index 0000000000..88351fd5a7 --- /dev/null +++ b/testsuite/tests/th/T16666.hs @@ -0,0 +1,11 @@ +{-# LANGUAGE ConstraintKinds #-} +{-# LANGUAGE FlexibleInstances #-} +{-# LANGUAGE MultiParamTypeClasses #-} +{-# LANGUAGE QuantifiedConstraints #-} +{-# LANGUAGE TemplateHaskell #-} +{-# LANGUAGE UndecidableInstances #-} +module T16666 where + +$([d| class (c => d) => Implies c d + instance (c => d) => Implies c d + |]) diff --git a/testsuite/tests/th/T16666.stderr b/testsuite/tests/th/T16666.stderr new file mode 100644 index 0000000000..8264967396 --- /dev/null +++ b/testsuite/tests/th/T16666.stderr @@ -0,0 +1,7 @@ +T16666.hs:(9,3)-(11,6): Splicing declarations + [d| class (c => d) => Implies c d + + instance (c => d) => Implies c d |] + ======> + class (c => d) => Implies c d + instance (c => d) => Implies c d diff --git a/testsuite/tests/th/all.T b/testsuite/tests/th/all.T index f9738615c7..37d21c3707 100644 --- a/testsuite/tests/th/all.T +++ b/testsuite/tests/th/all.T @@ -473,3 +473,4 @@ test('T16195', normal, multimod_compile, ['T16195.hs', '-v0']) test('T16293b', normal, compile, ['']) test('T16326_TH', normal, compile, ['-v0 -ddump-splices -dsuppress-uniques']) test('T14741', normal, compile_and_run, ['']) +test('T16666', normal, compile, ['-v0 -ddump-splices -dsuppress-uniques']) |