[project @ 2004-08-13 13:04:50 by simonmar]
[ghc-hetmet.git] / ghc / compiler / basicTypes / Name.lhs
index dc8ee65..702b07f 100644 (file)
@@ -11,8 +11,8 @@ module Name (
        -- The Name type
        Name,                                   -- Abstract
        mkInternalName, mkSystemName, 
-       mkSystemNameEncoded, mkSystemTvNameEncoded, mkFCallName,
-       mkIPName,
+       mkSystemNameEncoded, mkSysTvName, 
+       mkFCallName, mkIPName,
        mkExternalName, mkWiredInName,
 
        nameUnique, setNameUnique,
@@ -212,10 +212,10 @@ mkSystemNameEncoded uniq fs = Name { n_uniq = uniq, n_sort = System,
                                     n_occ = mkSysOccFS varName fs, 
                                     n_loc = noSrcLoc }
 
-mkSystemTvNameEncoded :: Unique -> EncodedFS -> Name
-mkSystemTvNameEncoded uniq fs = Name { n_uniq = uniq, n_sort = System, 
-                                      n_occ = mkSysOccFS tvName fs, 
-                                      n_loc = noSrcLoc }
+mkSysTvName :: Unique -> EncodedFS -> Name
+mkSysTvName uniq fs = Name { n_uniq = uniq, n_sort = System, 
+                            n_occ = mkSysOccFS tvName fs, 
+                            n_loc = noSrcLoc }
 
 mkFCallName :: Unique -> EncodedString -> Name
        -- The encoded string completely describes the ccall
@@ -252,7 +252,7 @@ localiseName n = n { n_sort = Internal }
 
 \begin{code}
 hashName :: Name -> Int
-hashName name = iBox (getKey (nameUnique name))
+hashName name = getKey (nameUnique name)
 \end{code}
 
 
@@ -323,9 +323,7 @@ pprExternal sty name uniq mod occ mb_p is_wired
 
 pprInternal sty uniq occ
   | codeStyle sty  = pprUnique uniq
-  | debugStyle sty = hsep [pprOccName occ, text "{-", 
-                          text (briefOccNameFlavour occ), 
-                          pprUnique uniq, text "-}"]
+  | debugStyle sty = pprOccName occ <> text "{-" <> pprUnique uniq <> text "-}"
   | otherwise      = pprOccName occ    -- User style
 
 -- Like Internal, except that we only omit the unique in Iface style