1
1
mirror of https://github.com/github/semantic.git synced 2024-12-18 04:11:48 +03:00

Rethrow failures.

This commit is contained in:
Rob Rix 2020-01-13 16:18:18 -05:00
parent 174cce6c73
commit ae7e3aeb50
No known key found for this signature in database
GPG Key ID: 2BE643E01DC032AE

View File

@ -10,7 +10,7 @@ module Tagging (benchmarks) where
import Control.Carrier.Parse.Measured import Control.Carrier.Parse.Measured
import Control.Carrier.Reader import Control.Carrier.Reader
import Control.Concurrent.Async (forConcurrently) import Control.Concurrent.Async (forConcurrently)
import Control.Exception (displayException) import Control.Exception (displayException, throwIO)
import Control.Lens import Control.Lens
import Control.Monad import Control.Monad
import Data.Blob import Data.Blob
@ -66,9 +66,7 @@ runTagging mode dir glob = nfIO . withOptions testOptions $ \ config logger stat
let session = TaskSession config "-" False logger statter let session = TaskSession config "-" False logger statter
files <- globDir1 (compile glob) (Path.toString dir) files <- globDir1 (compile glob) (Path.toString dir)
let paths = Path.relFile <$> files let paths = Path.relFile <$> files
for_ paths $ \ file -> do for_ paths (runTask session . runParse . parseSymbolsFilePath mode >=> either throwIO pure)
_ <- runTask session (runParse (parseSymbolsFilePath mode file))
pure ()
parseSymbolsFilePath :: parseSymbolsFilePath ::
( Has (Error SomeException) sig m ( Has (Error SomeException) sig m