never executed always true always false
    1 module HelVM.HelMA.Automata.LazyK.Evaluator (
    2   evalParams,
    3   evalSource,
    4   reduceSource,
    5 ) where
    6 
    7 import           HelVM.HelMA.Automata.LazyK.Automaton
    8 import           HelVM.HelMA.Automata.LazyK.InputEncoder
    9 import           HelVM.HelMA.Automata.LazyK.Lambda
   10 import           HelVM.HelMA.Automata.LazyK.Parser
   11 
   12 import           HelVM.HelMA.Automata.LazyK.Reducer
   13 
   14 import           HelVM.HelMA.Automaton.API.EvalParams
   15 import           HelVM.HelMA.Automaton.API.IOTypes
   16 
   17 import           HelVM.HelMA.Automaton.IO.BusinessIO
   18 
   19 evalParams :: BIO m => EvalParams -> m ()
   20 evalParams = evalSource . source
   21 
   22 evalSource :: BIO m => Source -> m ()
   23 evalSource = evalLambda <=< parse
   24 
   25 evalLambda :: BIO m => Lambda -> m ()
   26 evalLambda lambda = (run . reduce . App lambda . readInput) =<< wGetContentsBS
   27 
   28 reduceSource :: BIO m => Source -> m Source
   29 reduceSource s = show . reduce <$> parse s