moduleCSPM.Evaluator(evaluateExp,evaluateDecl,evaluateFile,getBoundNames,addToEnvironment,initEvaluator,runFromStateToState,EvaluationMonad,runEvaluator,EvaluationState,)whereimportCSPM.DataStructures.NamesimportCSPM.DataStructures.SyntaximportCSPM.DataStructures.TypesimportCSPM.Evaluator.BuiltInFunctionsimportCSPM.Evaluator.DeclBindimportCSPM.Evaluator.EnvironmentimportCSPM.Evaluator.ExprimportCSPM.Evaluator.ModuleimportCSPM.Evaluator.MonadimportCSPM.Evaluator.ValuesrunFromStateToState::EvaluationState->EvaluationMonada->(a,EvaluationState)runFromStateToStatestprog=runEvaluatorst$dor<-progs<-getStatereturn(r,s)-- | The environment to use initially. This uses the IO monad as -- the EvaluationMonad cannot be used without a valid environment.initEvaluator::EvaluationStateinitEvaluator=runEvaluator(EvaluationStatenew)$injectBuiltInFunctionsgetStateevaluateExp::TCExp->EvaluationMonadValueevaluateExpe=evale-- | Evaluates the declaration but doesn't add it to the current environment.evaluateDecl::TCDecl->EvaluationMonad[(Name,Value)]evaluateDecld=bindDecls[d]-- | Evaluates the declaration but doesn't add it to the current environment.evaluateFile::[TCModule]->EvaluationMonad[(Name,Value)]evaluateFilems=bindModulesmsgetBoundNames::EvaluationMonad[Name]getBoundNames=getEnvironment>>=return.filter(not.isInternal).mapfst.flattenaddToEnvironment::EvaluationMonad[(Name,Value)]->EvaluationMonadEvaluationStateaddToEnvironmentbs=addScopeAndBindMbsgetState