From 93da9f95b0c921f0d50a34bd1202c6428ff7ba5b Mon Sep 17 00:00:00 2001 From: Simon Peyton Jones Date: Thu, 14 Sep 2017 17:20:14 +0100 Subject: Add test for Trac #14232 --- testsuite/tests/typecheck/should_fail/T14232.hs | 4 ++++ testsuite/tests/typecheck/should_fail/T14232.stderr | 4 ++++ testsuite/tests/typecheck/should_fail/all.T | 1 + 3 files changed, 9 insertions(+) create mode 100644 testsuite/tests/typecheck/should_fail/T14232.hs create mode 100644 testsuite/tests/typecheck/should_fail/T14232.stderr diff --git a/testsuite/tests/typecheck/should_fail/T14232.hs b/testsuite/tests/typecheck/should_fail/T14232.hs new file mode 100644 index 0000000000..79da2cc7b5 --- /dev/null +++ b/testsuite/tests/typecheck/should_fail/T14232.hs @@ -0,0 +1,4 @@ +module T14232 where + +f :: (String -> a) String -> a +f g s = g s diff --git a/testsuite/tests/typecheck/should_fail/T14232.stderr b/testsuite/tests/typecheck/should_fail/T14232.stderr new file mode 100644 index 0000000000..a497be7b19 --- /dev/null +++ b/testsuite/tests/typecheck/should_fail/T14232.stderr @@ -0,0 +1,4 @@ + +T14232.hs:3:6: error: + • Expected kind ‘* -> *’, but ‘String -> a’ has kind ‘*’ + • In the type signature: f :: (String -> a) String -> a diff --git a/testsuite/tests/typecheck/should_fail/all.T b/testsuite/tests/typecheck/should_fail/all.T index 5fbbee0e21..07a893bb53 100644 --- a/testsuite/tests/typecheck/should_fail/all.T +++ b/testsuite/tests/typecheck/should_fail/all.T @@ -455,3 +455,4 @@ test('T13902', normal, compile_fail, ['']) test('T11963', normal, compile_fail, ['']) test('T14000', normal, compile_fail, ['']) test('T14055', normal, compile_fail, ['']) +test('T14232', normal, compile_fail, ['']) -- cgit v1.2.1