Commit 27842ec1 authored by Ben Gamari's avatar Ben Gamari 🐢
Browse files

Fix thinko that crept into D1908

RyanGlScott updated the Diff only after I had merged it.
parent 0c420cb6
...@@ -1806,7 +1806,7 @@ only Foldable instances are not possible for function types at all. ...@@ -1806,7 +1806,7 @@ only Foldable instances are not possible for function types at all.
Given (data T a = T a a (T a) deriving Foldable), we get: Given (data T a = T a a (T a) deriving Foldable), we get:
instance Foldable T where instance Foldable T where
foldr f z (T1 x1 x2 x3) = foldr f z (T x1 x2 x3) =
$(foldr 'a 'a) x1 ( $(foldr 'a 'a) x2 ( $(foldr 'a '(T a)) x3 z ) ) $(foldr 'a 'a) x1 ( $(foldr 'a 'a) x2 ( $(foldr 'a '(T a)) x3 z ) )
-XDeriveFoldable is different from -XDeriveFunctor in that it filters out -XDeriveFoldable is different from -XDeriveFunctor in that it filters out
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment