I am encountering this error when I try to derive an instance.
Cannot derive well-kinded instance of form ‘HFunctor (ControlFlowCMD ...)’
Class ‘HFunctor’ expects an argument of kind ‘(* -> *, *)
-> * -> *’
• In the newtype declaration for ‘ControlFlowCMD’
I am trying to do this:
newtype ControlFlowCMD fs a = ControlFlowCMD (ControlCMD fs a)
deriving HFunctor via (ControlCMD fs a)
You can see the data type and instance I am basing my type on and trying to derive here, on line 278. I am not that used to using deriving via - could anyone explain what this error means and how I would fix it?