From 115c21074bf0af4c166bd0d9f9aa09f0c3636a58 Mon Sep 17 00:00:00 2001 From: Rob Rix Date: Fri, 4 May 2018 18:41:46 -0400 Subject: [PATCH] Rephrase ImportGraphAnalysis as a composed handler. --- src/Semantic/Graph.hs | 21 +++++++++------------ 1 file changed, 9 insertions(+), 12 deletions(-) diff --git a/src/Semantic/Graph.hs b/src/Semantic/Graph.hs index 0832dc26f..2003ad853 100644 --- a/src/Semantic/Graph.hs +++ b/src/Semantic/Graph.hs @@ -62,18 +62,15 @@ parseModule parser rootDir file = do moduleForBlob rootDir blob <$> parse parser blob -type ImportGraphAnalysis term - = ImportGraphing - ( BadAddresses - ( BadModuleResolutions - ( BadVariables - ( BadValues - ( BadSyntax - ( Erroring (Analysis.LoadError term) - ( Evaluating - (Located Precise term) - term - (Value (Located Precise term))))))))) +importGraphAnalysis + = evaluating + . erroring @(Analysis.LoadError term) + . resumingBadSyntax + . resumingBadValues + . resumingBadVariables + . resumingBadModuleResolutions + . resumingBadAddresses + . importGraphing -- | Render the import graph for a given 'Package'. graphImports :: ( Show ann