diff --git a/bench/Main.hs b/bench/Main.hs index 94400e61a..895a33cf1 100644 --- a/bench/Main.hs +++ b/bench/Main.hs @@ -11,10 +11,10 @@ import Control.Monad -- project—coercing the result into a string will suffice, though it throws off the -- memory allocation results a bit. pyEval :: FilePath -> Benchmarkable -pyEval = whnfIO . fmap show . evaluatePythonFile . ("bench/bench-fixtures/python/" <>) +pyEval = whnfIO . fmap show . evalPythonProject . ("bench/bench-fixtures/python/" <>) rbEval :: FilePath -> Benchmarkable -rbEval = whnfIO . fmap show . evaluateRubyFile . ("bench/bench-fixtures/ruby/" <>) +rbEval = whnfIO . fmap show . evalRubyProject . ("bench/bench-fixtures/ruby/" <>) main :: IO () main = defaultMain diff --git a/src/Semantic/Util.hs b/src/Semantic/Util.hs index 7dfcf87c5..50033b24b 100644 --- a/src/Semantic/Util.hs +++ b/src/Semantic/Util.hs @@ -80,10 +80,6 @@ pythonPrelude = Just $ File (TypeLevel.symbolVal (Proxy :: Proxy (PreludePath Py -- Evaluate a project, starting at a single entrypoint. evaluateProject parser lang prelude path = evaluatePackage <$> runTask (readProject Nothing path lang [] >>= parsePackage parser prelude) -evalRubyFile path = interpret @(JustEvaluating Ruby.Term) <$> evaluateFile rubyParser path -evaluateFile parser path = evaluateModule <$> runTask (parseModule parser Nothing (file path)) - - parseFile :: Parser term -> FilePath -> IO term parseFile parser = runTask . (parse parser <=< readBlob . file)