Skip to content

Recursion tactic doesn't fire when deriving mutual recursion #1518

@isovector

Description

@isovector

From AutoThetaFix.hs test:

data Fix f a = Fix (f (Fix f a))

instance ( Functor f
           -- FIXME(sandy): Unfortunately, the recursion tactic fails to fire
           -- on this case. By explicitly adding the @Functor (Fix f)@
           -- dictionary, we can get Wingman to generate the right definition.
         , Functor (Fix f)
         ) => Functor (Fix f) where
  fmap = _

Note the FIXME. Recursion should be able to handle this just fine, but it doesn't! Unclear why, but I intend to find out.

Metadata

Metadata

Assignees

No one assigned

    Labels

    component: wingmantype: bugSomething isn't right: doesn't work as intended, documentation is missing/outdated, etc..

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions