[commit: ghc] master: basicTypes: detabify/dewhitespace NameEnv (1b55153)

git at git.haskell.org git at git.haskell.org
Wed Aug 20 08:48:28 UTC 2014


Repository : ssh://git@git.haskell.org/ghc

On branch  : master
Link       : http://ghc.haskell.org/trac/ghc/changeset/1b551534cbdf7ac32d18cf5c6fb40e5e79892f4b/ghc

>---------------------------------------------------------------

commit 1b551534cbdf7ac32d18cf5c6fb40e5e79892f4b
Author: Austin Seipp <austin at well-typed.com>
Date:   Wed Aug 20 03:45:44 2014 -0500

    basicTypes: detabify/dewhitespace NameEnv
    
    Signed-off-by: Austin Seipp <austin at well-typed.com>


>---------------------------------------------------------------

1b551534cbdf7ac32d18cf5c6fb40e5e79892f4b
 compiler/basicTypes/NameEnv.lhs | 76 ++++++++++++++++++-----------------------
 1 file changed, 34 insertions(+), 42 deletions(-)

diff --git a/compiler/basicTypes/NameEnv.lhs b/compiler/basicTypes/NameEnv.lhs
index f396277..1fe908b 100644
--- a/compiler/basicTypes/NameEnv.lhs
+++ b/compiler/basicTypes/NameEnv.lhs
@@ -6,26 +6,19 @@
 
 \begin{code}
 {-# LANGUAGE CPP #-}
-{-# OPTIONS_GHC -fno-warn-tabs #-}
--- The above warning supression flag is a temporary kludge.
--- While working on this module you are encouraged to remove it and
--- detab the module (please do the detabbing in a separate patch). See
---     http://ghc.haskell.org/trac/ghc/wiki/Commentary/CodingStyle#TabsvsSpaces
--- for details
-
 module NameEnv (
-	-- * Var, Id and TyVar environments (maps) 
-	NameEnv, 
+        -- * Var, Id and TyVar environments (maps)
+        NameEnv,
 
-	-- ** Manipulating these environments
-	mkNameEnv,
-	emptyNameEnv, unitNameEnv, nameEnvElts, nameEnvUniqueElts,
-	extendNameEnv_C, extendNameEnv_Acc, extendNameEnv,
+        -- ** Manipulating these environments
+        mkNameEnv,
+        emptyNameEnv, unitNameEnv, nameEnvElts, nameEnvUniqueElts,
+        extendNameEnv_C, extendNameEnv_Acc, extendNameEnv,
         extendNameEnvList, extendNameEnvList_C,
-	foldNameEnv, filterNameEnv,
-	plusNameEnv, plusNameEnv_C, alterNameEnv,
-	lookupNameEnv, lookupNameEnv_NF, delFromNameEnv, delListFromNameEnv,
-	elemNameEnv, mapNameEnv,
+        foldNameEnv, filterNameEnv,
+        plusNameEnv, plusNameEnv_C, alterNameEnv,
+        lookupNameEnv, lookupNameEnv_NF, delFromNameEnv, delListFromNameEnv,
+        elemNameEnv, mapNameEnv,
 
         -- ** Dependency analysis
         depAnal
@@ -41,9 +34,9 @@ import Maybes
 \end{code}
 
 %************************************************************************
-%*									*
+%*                                                                      *
 \subsection{Name environment}
-%*									*
+%*                                                                      *
 %************************************************************************
 
 \begin{code}
@@ -67,50 +60,50 @@ depAnal get_defs get_uses nodes
 
 
 %************************************************************************
-%*									*
+%*                                                                      *
 \subsection{Name environment}
-%*									*
+%*                                                                      *
 %************************************************************************
 
 \begin{code}
-type NameEnv a = UniqFM a	-- Domain is Name
+type NameEnv a = UniqFM a       -- Domain is Name
 
-emptyNameEnv   	   :: NameEnv a
-mkNameEnv	   :: [(Name,a)] -> NameEnv a
-nameEnvElts    	   :: NameEnv a -> [a]
+emptyNameEnv       :: NameEnv a
+mkNameEnv          :: [(Name,a)] -> NameEnv a
+nameEnvElts        :: NameEnv a -> [a]
 nameEnvUniqueElts  :: NameEnv a -> [(Unique, a)]
 alterNameEnv       :: (Maybe a-> Maybe a) -> NameEnv a -> Name -> NameEnv a
 extendNameEnv_C    :: (a->a->a) -> NameEnv a -> Name -> a -> NameEnv a
 extendNameEnv_Acc  :: (a->b->b) -> (a->b) -> NameEnv b -> Name -> a -> NameEnv b
-extendNameEnv  	   :: NameEnv a -> Name -> a -> NameEnv a
-plusNameEnv    	   :: NameEnv a -> NameEnv a -> NameEnv a
-plusNameEnv_C  	   :: (a->a->a) -> NameEnv a -> NameEnv a -> NameEnv a
+extendNameEnv      :: NameEnv a -> Name -> a -> NameEnv a
+plusNameEnv        :: NameEnv a -> NameEnv a -> NameEnv a
+plusNameEnv_C      :: (a->a->a) -> NameEnv a -> NameEnv a -> NameEnv a
 extendNameEnvList  :: NameEnv a -> [(Name,a)] -> NameEnv a
 extendNameEnvList_C :: (a->a->a) -> NameEnv a -> [(Name,a)] -> NameEnv a
-delFromNameEnv 	   :: NameEnv a -> Name -> NameEnv a
+delFromNameEnv     :: NameEnv a -> Name -> NameEnv a
 delListFromNameEnv :: NameEnv a -> [Name] -> NameEnv a
-elemNameEnv    	   :: Name -> NameEnv a -> Bool
-unitNameEnv    	   :: Name -> a -> NameEnv a
-lookupNameEnv  	   :: NameEnv a -> Name -> Maybe a
+elemNameEnv        :: Name -> NameEnv a -> Bool
+unitNameEnv        :: Name -> a -> NameEnv a
+lookupNameEnv      :: NameEnv a -> Name -> Maybe a
 lookupNameEnv_NF   :: NameEnv a -> Name -> a
-foldNameEnv	   :: (a -> b -> b) -> b -> NameEnv a -> b
-filterNameEnv	   :: (elt -> Bool) -> NameEnv elt -> NameEnv elt
-mapNameEnv	   :: (elt1 -> elt2) -> NameEnv elt1 -> NameEnv elt2
+foldNameEnv        :: (a -> b -> b) -> b -> NameEnv a -> b
+filterNameEnv      :: (elt -> Bool) -> NameEnv elt -> NameEnv elt
+mapNameEnv         :: (elt1 -> elt2) -> NameEnv elt1 -> NameEnv elt2
 
 nameEnvElts x         = eltsUFM x
-emptyNameEnv  	      = emptyUFM
+emptyNameEnv          = emptyUFM
 unitNameEnv x y       = unitUFM x y
 extendNameEnv x y z   = addToUFM x y z
 extendNameEnvList x l = addListToUFM x l
 lookupNameEnv x y     = lookupUFM x y
 alterNameEnv          = alterUFM
 mkNameEnv     l       = listToUFM l
-elemNameEnv x y 	 = elemUFM x y
-foldNameEnv a b c	 = foldUFM a b c 
-plusNameEnv x y		 = plusUFM x y 
-plusNameEnv_C f x y	 = plusUFM_C f x y 
+elemNameEnv x y          = elemUFM x y
+foldNameEnv a b c        = foldUFM a b c
+plusNameEnv x y          = plusUFM x y
+plusNameEnv_C f x y      = plusUFM_C f x y
 extendNameEnv_C f x y z  = addToUFM_C f x y z
-mapNameEnv f x         	 = mapUFM f x
+mapNameEnv f x           = mapUFM f x
 nameEnvUniqueElts x      = ufmToList x
 extendNameEnv_Acc x y z a b  = addToUFM_Acc x y z a b
 extendNameEnvList_C x y z = addListToUFM_C x y z
@@ -120,4 +113,3 @@ filterNameEnv x y       = filterUFM x y
 
 lookupNameEnv_NF env n = expectJust "lookupNameEnv_NF" (lookupNameEnv env n)
 \end{code}
-



More information about the ghc-commits mailing list