You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
beginMultiline :: HaskelineT m ()
endMultiline :: HaskelineT m ()
-- returns a list of lines since the enclosing beginMultiline
-- alternatively, this could be managed by the caller
multilineContext :: HaskelineT m [String]
allowing something like
cmd :: Command (HaskelineT IO)
cmd s = do
context <- multilineContext
if Parser.isIncomplete (context ++ [s])
then beginMultiline
else do
endMultiline
-- process (context ++ [s]) as a multi-line chunk
The text was updated successfully, but these errors were encountered:
Currently, there's a way to toggle multiline mode based on matching a specific commmand:
However, it would be nice to provide a way to toggle this mode based on parsing information, to make something like the following work
A possible API for this would be:
allowing something like
The text was updated successfully, but these errors were encountered: