Skip to content

Commit

Permalink
fix formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
marcosh committed Oct 28, 2024
1 parent 13d0ead commit a9da2c2
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 15 deletions.
6 changes: 3 additions & 3 deletions src/Crem/Render/RenderFlow.hs
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,9 @@ data TreeMetadata a
instance NoThunks a => NoThunks (TreeMetadata a) where
showTypeOf _ = "TreeMetadata"
wNoThunks ctxt tm =
case tm of
LeafLabel x -> noThunks ctxt x
BinaryLabel x y -> allNoThunks [noThunks ctxt x, noThunks ctxt y]
case tm of
LeafLabel x -> noThunks ctxt x
BinaryLabel x y -> allNoThunks [noThunks ctxt x, noThunks ctxt y]

-- | Given a `StateMachineT` and a `TreeMetadata` of @MachineLabel@s, we can
-- create a flow representation of our machine.
Expand Down
14 changes: 7 additions & 7 deletions src/Crem/StateMachine.hs
Original file line number Diff line number Diff line change
Expand Up @@ -78,13 +78,13 @@ data StateMachineT m input output where
instance NoThunks (StateMachineT m input output) where
showTypeOf _ = "StateMachineT"
wNoThunks ctxt sm =
case sm of
Basic _ -> return Nothing
Sequential x y -> allNoThunks [noThunks ctxt x, noThunks ctxt y]
Parallel x y -> allNoThunks [noThunks ctxt x, noThunks ctxt y]
Alternative x y -> allNoThunks [noThunks ctxt x, noThunks ctxt y]
Feedback x y -> allNoThunks [noThunks ctxt x, noThunks ctxt y]
Kleisli x y -> allNoThunks [noThunks ctxt x, noThunks ctxt y]
case sm of
Basic _ -> return Nothing
Sequential x y -> allNoThunks [noThunks ctxt x, noThunks ctxt y]
Parallel x y -> allNoThunks [noThunks ctxt x, noThunks ctxt y]
Alternative x y -> allNoThunks [noThunks ctxt x, noThunks ctxt y]
Feedback x y -> allNoThunks [noThunks ctxt x, noThunks ctxt y]
Kleisli x y -> allNoThunks [noThunks ctxt x, noThunks ctxt y]

-- | A `StateMachine` is an effectful machine for every possible monad @m@.
-- Needing to work for every monad, in fact it can not perform any kind of
Expand Down
10 changes: 5 additions & 5 deletions src/Crem/Topology.hs
Original file line number Diff line number Diff line change
Expand Up @@ -68,11 +68,11 @@ data AllowTransition (topology :: Topology vertex) (initial :: vertex) (final ::
instance NoThunks (AllowTransition topology initial final) where
showTypeOf _ = "AllowTransition"
wNoThunks ctxt at =
case at of
AllowIdentityEdge -> return Nothing
AllowFirstEdge -> return Nothing
AllowAddingEdge x -> noThunks ctxt x
AllowAddingVertex x -> noThunks ctxt x
case at of
AllowIdentityEdge -> return Nothing
AllowFirstEdge -> return Nothing
AllowAddingEdge x -> noThunks ctxt x
AllowAddingVertex x -> noThunks ctxt x

-- | The `AllowedTransition` type class enables to automatically perform proof search
-- for a `AllowTransition` term.
Expand Down

0 comments on commit a9da2c2

Please sign in to comment.