[project @ 1996-07-25 20:43:49 by partain]
[ghc-hetmet.git] / ghc / compiler / basicTypes / SrcLoc.lhs
index 423b4b3..e12b0db 100644 (file)
@@ -15,14 +15,17 @@ module SrcLoc (
 
        mkSrcLoc, mkSrcLoc2,    -- the usual
        mkUnknownSrcLoc,        -- "I'm sorry, I haven't a clue"
+       mkIfaceSrcLoc,          -- Unknown place in an interface
+                               -- (this one can die eventually ToDo)
        mkBuiltinSrcLoc,        -- something wired into the compiler
        mkGeneratedSrcLoc,      -- code generated within the compiler
        unpackSrcLoc
     ) where
 
-import Outputable
+IMP_Ubiq()
+
+import PprStyle                ( PprStyle(..) )
 import Pretty
-import Util
 \end{code}
 
 %************************************************************************
@@ -57,6 +60,7 @@ Things to make 'em:
 mkSrcLoc           = SrcLoc
 mkSrcLoc2 x IBOX(y) = SrcLoc2 x y
 mkUnknownSrcLoc            = SrcLoc SLIT("<unknown>") SLIT("<unknown>")
+mkIfaceSrcLoc      = SrcLoc SLIT("<an interface file>") SLIT("<unknown>")
 mkBuiltinSrcLoc            = SrcLoc SLIT("<built-into-the-compiler>") SLIT("<none>")
 mkGeneratedSrcLoc   = SrcLoc SLIT("<compiler-generated-code>") SLIT("<none>")
 
@@ -73,7 +77,7 @@ unpackSrcLoc (SrcLoc2 src_file src_line) = (src_file, _PK_ (show IBOX(src_line))
 \begin{code}
 instance Outputable SrcLoc where
     ppr PprForUser (SrcLoc src_file src_line)
-      = ppBesides [ ppChar '"', ppPStr src_file, ppPStr SLIT("\", line "), ppPStr src_line ]
+      = ppBesides [ ppChar '"', ppPStr src_file, ppStr "\", line ", ppPStr src_line ]
 
     ppr sty (SrcLoc src_file src_line)
       = ppBesides [ppPStr SLIT("{-# LINE "), ppPStr src_line, ppSP,