1
1
mirror of https://github.com/github/semantic.git synced 2024-11-28 01:47:01 +03:00

Merge pull request #1934 from github/charliesome/test-type-annos

Add type annotation to testEvaluating
This commit is contained in:
Rob Rix 2018-06-07 11:00:02 -04:00 committed by GitHub
commit b7fa65207a

View File

@ -38,6 +38,7 @@ import Data.Range as X
import Data.Record as X
import Data.Source as X
import Data.Span as X
import Data.Sum
import Data.Term as X
import Parsing.Parser as X
import Rendering.Renderer as X hiding (error)
@ -77,6 +78,34 @@ readFilePair :: Both FilePath -> IO BlobPair
readFilePair paths = let paths' = fmap file paths in
runBothWith IO.readFilePair paths'
testEvaluating :: TermEvaluator term Precise
(Value Precise (Eff effects))
'[ Resumable (ValueError Precise (Eff effects))
, Resumable (AddressError Precise (Value Precise (Eff effects)))
, Resumable EvalError, Resumable (EnvironmentError Precise)
, Resumable ResolutionError
, Resumable (Unspecialized (Value Precise (Eff effects)))
, Resumable (LoadError Precise (Value Precise (Eff effects)))
, Fresh
, State (Heap Precise Latest (Value Precise (Eff effects)))
, State (ModuleTable (Maybe (Value Precise (Eff effects), Environment Precise)))
, Trace
]
[(Value Precise (Eff effects), Environment Precise)]
-> ((Either
(SomeExc
(Data.Sum.Sum
'[ ValueError Precise (Eff effects)
, AddressError Precise (Value Precise (Eff effects))
, EvalError
, EnvironmentError Precise
, ResolutionError
, Unspecialized (Value Precise (Eff effects))
, LoadError Precise (Value Precise (Eff effects))
]))
[(Value Precise (Eff effects), Environment Precise)],
EvaluatingState Precise (Value Precise (Eff effects))),
[String])
testEvaluating
= run
. runReturningTrace