| Safe Haskell | Safe | 
|---|---|
| Language | Haskell2010 | 
Sutori.Monad.Actions
Description
- whenVerbose :: SutMonad () -> SutMonad ()
 - runSutMonad :: SutMonad a -> Options -> SutState -> Except (SutError, SutLog) ((a, SutState), SutLogger)
 - insertScope :: SutMonad ()
 - removeScope :: SutMonad ()
 - parserCurrentScope :: SutState -> Scope
 - setErrorCode :: SutError -> SutMonad ()
 - functionStarts :: SutMonad ()
 
Documentation
whenVerbose :: SutMonad () -> SutMonad () Source #
Run a monadic action only if verbose if turned on
runSutMonad :: SutMonad a -> Options -> SutState -> Except (SutError, SutLog) ((a, SutState), SutLogger) Source #
Run the monad with a given action
insertScope :: SutMonad () Source #
Inserts a new scope into the parse
- Inserts the scope into the open scopes set.
 - Pushes the scope into the open scopes stack.
 - Saves the current offset to return to it once the scope is closed.
 
removeScope :: SutMonad () Source #
Removes last scope from the parse
- Pops closing scope from stack of open scopes.
 - Removes closing scope from set of open scopes.
 - Recovers previous offset to write new data over just-closed scope
 
parserCurrentScope :: SutState -> Scope Source #
Get the current open scope
setErrorCode :: SutError -> SutMonad () Source #
Set the current error code for the compilation
functionStarts :: SutMonad () Source #