Reject derivable type classes with higher-rank methods
Trac #864 suggested a derivable type class with a higher-rank method. In principle this is quite do-able, but in practice the mechanism works by generating source code and then doing type inference. To make this work with higher-rank types would require impredicative polymorphism. And we do have that, so it could probably be made to work by generating (source-level) type annotations. But it's real work, so I'm settling for generating a decent error message rather than crashing.
Showing with 37 additions and 19 deletions