X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=compiler%2FbasicTypes%2FNameSet.lhs;h=e60ea23d278e0b33f565d7e72262aadf7dd36685;hb=08652e67c4d5d9a40687f93c286021a867c1bca0;hp=1c411592941844ac12382b561f9b0ab2351a44bb;hpb=ad94d40948668032189ad22a0ad741ac1f645f50;p=ghc-hetmet.git diff --git a/compiler/basicTypes/NameSet.lhs b/compiler/basicTypes/NameSet.lhs index 1c41159..e60ea23 100644 --- a/compiler/basicTypes/NameSet.lhs +++ b/compiler/basicTypes/NameSet.lhs @@ -4,13 +4,6 @@ % \begin{code} -{-# OPTIONS -w #-} --- The above warning supression flag is a temporary kludge. --- While working on this module you are encouraged to remove it and fix --- any warnings in the module. See --- http://hackage.haskell.org/trac/ghc/wiki/CodingStyle#Warnings --- for details - module NameSet ( -- Sets of Names NameSet, @@ -104,6 +97,7 @@ mkFVs :: [Name] -> FreeVars delFV :: Name -> FreeVars -> FreeVars delFVs :: [Name] -> FreeVars -> FreeVars +isEmptyFVs :: NameSet -> Bool isEmptyFVs = isEmptyNameSet emptyFVs = emptyNameSet plusFVs = unionManyNameSets @@ -154,14 +148,14 @@ plusDU = (++) duDefs :: DefUses -> Defs duDefs dus = foldr get emptyNameSet dus where - get (Nothing, u1) d2 = d2 - get (Just d1, u1) d2 = d1 `unionNameSets` d2 + get (Nothing, _u1) d2 = d2 + get (Just d1, _u1) d2 = d1 `unionNameSets` d2 duUses :: DefUses -> Uses -- Just like allUses, but defs are not eliminated duUses dus = foldr get emptyNameSet dus where - get (d1, u1) u2 = u1 `unionNameSets` u2 + get (_d1, u1) u2 = u1 `unionNameSets` u2 allUses :: DefUses -> Uses -- Collect all uses, regardless of