Opened 12 months ago

Closed 12 months ago

Last modified 12 months ago

#8999 closed bug (duplicate)

Type synonym not normalized in instance head

Reported by: edsko Owned by:
Priority: normal Milestone:
Component: Compiler Version: 7.8.2
Keywords: Cc:
Operating System: Unknown/Multiple Architecture: Unknown/Multiple
Type of failure: None/Unknown Test Case:
Blocked By: Blocking:
Related Tickets: Differential Revisions:

Description

Consider

{-# LANGUAGE ConstraintKinds, KindSignatures #-}

type Foo (m :: * -> *) = Monad m

data T a = T (Maybe a)

instance Foo T where
  return = T Nothing

this gives the bogus error

T.hs:8:3: ‘return’ is not a (visible) method of class ‘Foo’

incidentally, it works okay when giving no where clause.

Change History (2)

comment:1 Changed 12 months ago by monoidal

  • Resolution set to duplicate
  • Status changed from new to closed

See #7543.

comment:2 Changed 12 months ago by edsko

Ah, apologies!

Note: See TracTickets for help on using tickets.