Infer types with flexible contexts
authorSimon Peyton Jones <simonpj@microsoft.com>
Thu, 9 Jul 2015 12:03:34 +0000 (13:03 +0100)
committerSimon Peyton Jones <simonpj@microsoft.com>
Thu, 9 Jul 2015 12:04:04 +0000 (13:04 +0100)
commitb5aabfbdb96ba8abf2748d089f40c267c2131215
treef5b204c8c20f23ac8845363f18de5f2a5d78fcbd
parentc58dc1a149128dcc923b6cd2b20b0139e765c50d
Infer types with flexible contexts

Responding to Trac #10608 and Trac #10351, I've reverted
to making type inference infer structured constraint like
    f :: C [t] => t -> t
even if -XFlexibleContexts is not set.  That elicits an
error message suggesting the flag.  The result is more
helpful than the error message you get otherwise.
compiler/typecheck/TcSimplify.hs
testsuite/tests/typecheck/should_fail/T10351.stderr
testsuite/tests/typecheck/should_fail/T6022.stderr
testsuite/tests/typecheck/should_fail/T8883.stderr