aboutsummaryrefslogtreecommitdiff
path: root/hsm-command/Hsm/Command/Command.hs
diff options
context:
space:
mode:
authorPaul Oliver <contact@pauloliver.dev>2025-01-16 19:22:18 -0800
committerPaul Oliver <contact@pauloliver.dev>2025-01-17 19:16:43 -0800
commite3ea039428545e185b38c5633fe3576ab32f1f8e (patch)
tree56ab8d1248b4387ceab6094305e7a75699c4e393 /hsm-command/Hsm/Command/Command.hs
parente1fa79eb713c249055fb23fcc6684a94f77d8368 (diff)
Cleans excessive type annotations
Diffstat (limited to 'hsm-command/Hsm/Command/Command.hs')
-rw-r--r--hsm-command/Hsm/Command/Command.hs5
1 files changed, 1 insertions, 4 deletions
diff --git a/hsm-command/Hsm/Command/Command.hs b/hsm-command/Hsm/Command/Command.hs
index 3b53287..53964c4 100644
--- a/hsm-command/Hsm/Command/Command.hs
+++ b/hsm-command/Hsm/Command/Command.hs
@@ -39,13 +39,10 @@ data Command
| Rotate Angle Speed Int
deriving (Binary, Generic, Read, Show)
-commandStream ::
- forall es. (Log :> es, Readline :> es)
- => S.Stream (Eff es) Command
+commandStream :: (Log :> es, Readline :> es) => S.Stream (Eff es) Command
commandStream =
S.mapMaybeM (parse . fromJust) $ S.takeWhile isJust $ S.repeatM readline
where
- parse :: String -> Eff es (Maybe Command)
parse string =
case readEither string of
Left err -> logAttention_ (pack err) >> return Nothing