X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=utils%2Fhpc%2FHpcShowTix.hs;h=c353e1b2780e80bad78c565f25005ddeca59dbc0;hb=92d9c522010a96acc86f2543163e3c36f1def3fc;hp=79c9fa342847aecb80ebcb16cf6363234502ef6e;hpb=a966047ca5c407f336a633d716d3d7b5ed29d231;p=ghc-hetmet.git diff --git a/utils/hpc/HpcShowTix.hs b/utils/hpc/HpcShowTix.hs index 79c9fa3..c353e1b 100644 --- a/utils/hpc/HpcShowTix.hs +++ b/utils/hpc/HpcShowTix.hs @@ -6,12 +6,14 @@ import Trace.Hpc.Util import HpcFlags -import qualified Data.Set as Set +import qualified HpcSet as Set -showtix_options = - [ excludeOpt,includeOpt,hpcDirOpt - , outputOpt - ] +showtix_options + = excludeOpt + . includeOpt + . srcDirOpt + . hpcDirOpt + . outputOpt showtix_plugin = Plugin { name = "show" , usage = "[OPTION] .. [ [ ..]]" @@ -35,12 +37,11 @@ showtix_main flags (prog:modNames) = do case optTixs of Nothing -> hpcError showtix_plugin $ "could not read .tix file : " ++ prog Just (Tix tixs) -> do - let modules = map tixModuleName tixs - - mixs <- sequence - [ readMix (hpcDirs hpcflags1) modName -- hard wired to .hpc for now - | modName <- modules - , allowModule hpcflags1 modName + tixs_mixs <- sequence + [ do mix <- readMixWithFlags hpcflags1 (tixModuleName tix) + return $ (tix,mix) + | tix <- tixs + , allowModule hpcflags1 (tixModuleName tix) ] let rjust n str = take (n - length str) (repeat ' ') ++ str @@ -53,8 +54,8 @@ showtix_main flags (prog:modNames) = do ] | ( TixModule modName hash _ tixs , Mix _file _timestamp _hash _tab entries - ) <- zip tixs mixs + ) <- tixs_mixs ] return () - \ No newline at end of file +