1
1
mirror of https://github.com/github/semantic.git synced 2024-12-20 13:21:59 +03:00

Generalize the type of listModulesInDir.

This commit is contained in:
Rob Rix 2018-05-06 10:28:02 -04:00
parent f2b0b2e3e6
commit 6f810134f3

View File

@ -209,9 +209,9 @@ resolve names = do
traceResolve :: (Show a, Show b) => a -> b -> c -> c
traceResolve name path = trace ("resolved " <> show name <> " -> " <> show path)
listModulesInDir :: MonadEvaluatable location term value effects
=> FilePath
-> Evaluator location term value effects [ModulePath]
listModulesInDir :: Member (Reader (ModuleTable [Module term])) effects
=> FilePath
-> Evaluator location term value effects [ModulePath]
listModulesInDir dir = ModuleTable.modulePathsInDir dir <$> askModuleTable
-- | Require/import another module by name and return it's environment and value.