Hello! Would it be possible somehow to serialize zippers using binary?
In particular I would like the following code to compile:
{-# LANGUAGE NoMonomorphismRestriction #-}
{-# LANGUAGE TemplateHaskell #-}
import Control.Lens
import Control.Zipper
import Data.Binary
import GHC.Generics (Generic)
data A = A { _x :: A }
| AEnd
deriving (Generic)
instance Binary A
makeLenses ''A
main = do
let z = zipper (A AEnd)
return ()
Hello! Would it be possible somehow to serialize zippers using binary? In particular I would like the following code to compile:
Or would it be simply impossible?