It would be nice if Commands could be read. My motivation is writing out the Commands into a file during testing and then having a --rerun option on the test runner to quickly repeat the last failed test.
Alternatively GHC can derive these as orphan instances in applications so this would be more of a nice quality of live improvement.
Costs: The deriving requires an unfortunate amount of language extention so maybe they should live in a seperate file.
{-# Language StandaloneDeriving, FlexibleInstances, FlexibleContexts, UndecidableInstances #-}
deriving instance Read (SM.Var)
deriving instance (Read (l SM.Symbolic), Read (r SM.Symbolic), Read (l SM.Concrete), Read (r SM.Concrete)) => Read (SM.Commands l r)
deriving instance (Read (l SM.Symbolic), Read (r SM.Symbolic), Read (l SM.Concrete), Read (r SM.Concrete)) => Read (SM.Command l r)
deriving instance (Read (b a)) => Read (SM.Reference a b)
deriving instance (Typeable a, Read a) => Read (SM.Concrete a)
deriving instance (Typeable a) => Read (SM.Symbolic a)
It would be nice if Commands could be read. My motivation is writing out the Commands into a file during testing and then having a --rerun option on the test runner to quickly repeat the last failed test.
Alternatively GHC can derive these as orphan instances in applications so this would be more of a nice quality of live improvement.
Costs: The deriving requires an unfortunate amount of language extention so maybe they should live in a seperate file.