Safe Haskell | Safe-Infered |
---|
- eval :: [String] -> (Term a, TermInfo) -> IO a
- exec :: (Term a, TermInfo) -> IO a
- run :: (Term (IO a), TermInfo) -> IO a
- evalChoice :: [String] -> (Term a, TermInfo) -> [(Term a, TermInfo)] -> IO a
- execChoice :: (Term a, TermInfo) -> [(Term a, TermInfo)] -> IO a
- runChoice :: (Term (IO a), TermInfo) -> [(Term (IO a), TermInfo)] -> IO a
Evaluating Terms
Simple command line programs
exec :: (Term a, TermInfo) -> IO aSource
exec
( term, termInfo )
executes a command line program, directly
grabbing the command line arguments from the environment and returning the
result upon successful evaluation of term
. On failure the program exits.
Multi-command command line programs
evalChoice :: [String] -> (Term a, TermInfo) -> [(Term a, TermInfo)] -> IO aSource
evalChoice
args mainTerm choices
is analogous to eval
, but for
programs that provide a choice of commands.