Properly handle mempty in Monoid Diag instance
This commit is contained in:
parent
9b566f2a63
commit
8949d05b3b
@ -45,7 +45,7 @@ instance Def DiagProp where
|
|||||||
|
|
||||||
|
|
||||||
instance Monoid Diag where
|
instance Monoid Diag where
|
||||||
mempty = Diag (\_ _ -> rect 0 0)
|
mempty = Diag (\_ _ -> mempty)
|
||||||
mappend d1 d2 = Diag g
|
mappend d1 d2 = Diag g
|
||||||
where
|
where
|
||||||
g p vt = mkDiag d1 p vt <> mkDiag d2 p vt
|
g p vt = mkDiag d1 p vt <> mkDiag d2 p vt
|
||||||
|
Loading…
Reference in New Issue
Block a user