2020-07-18 21:22:03 +03:00
|
|
|
import Language.Reflection
|
|
|
|
import DerivingEq
|
|
|
|
|
|
|
|
%language ElabReflection
|
|
|
|
|
|
|
|
-- This tree doesn't work
|
|
|
|
|
|
|
|
data TreeTwo a = BranchTwo (TreeTwo a) a (TreeTwo a)
|
|
|
|
| Leaf
|
|
|
|
|
|
|
|
Eq a => Eq (TreeTwo a) where
|
2021-01-12 15:23:28 +03:00
|
|
|
(==) = %runElab genEq `{ TreeTwo }
|