[project @ 1998-04-06 18:38:36 by sof]
[ghc-hetmet.git] / ghc / compiler / reader / PrefixSyn.lhs
index fdf9b11..9d1d8d0 100644 (file)
@@ -8,30 +8,26 @@ string from the current Haskell parser is converted.  Given in an
 order that follows the \tr{Prefix_Form} document.
 
 \begin{code}
-#include "HsVersions.h"
-
 module PrefixSyn (
        RdrBinding(..),
-       SYN_IE(RdrId),
+       RdrId,
        RdrMatch(..),
-       SYN_IE(SigConverter),
-       SYN_IE(SrcFile),
-       SYN_IE(SrcFun),
-       SYN_IE(SrcLine),
+       SigConverter,
+       SrcFile,
+       SrcFun,
+       SrcLine,
 
        readInteger
     ) where
 
-IMP_Ubiq()
-IMPORT_1_3(Char(isDigit))
+#include "HsVersions.h"
 
 import HsSyn
 import RdrHsSyn
+import BasicTypes      ( IfaceFlavour )
 import Util            ( panic )
-
-#ifdef REALLY_HASKELL_1_3
-ord = fromEnum :: Char -> Int
-#endif
+import SrcLoc           ( SrcLoc )
+import Char            ( isDigit, ord )
 
 type RdrId   = RdrName
 type SrcLine = Int
@@ -54,19 +50,9 @@ data RdrBinding
                        -- signatures are mysterious; we can't
                        -- tell if its a Sig or a ClassOpSig,
                        -- so we just save the pieces:
-  | RdrTySig           [RdrName]           -- vars getting sigs
-                       RdrNameHsType     -- the type
-                       SrcLoc
-
-  -- user pragmas come in in a Sig-ish way/form...
-  | RdrSpecValSig      [RdrNameSig]
-  | RdrInlineValSig    RdrNameSig
-  | RdrDeforestSig     RdrNameSig
-  | RdrMagicUnfoldingSig RdrNameSig
-  | RdrSpecInstSig     RdrNameSpecInstSig
-  | RdrSpecDataSig     RdrNameSpecDataSig
-
-type SigConverter = RdrBinding {- a Sig -} -> [RdrNameSig]
+  | RdrSig             RdrNameSig
+
+type SigConverter = RdrNameSig -> RdrNameSig
 \end{code}
 
 \begin{code}
@@ -80,7 +66,7 @@ data RdrMatch
   | RdrMatch_Guards
             SrcLine SrcFun
             RdrNamePat
-            [(RdrNameHsExpr, RdrNameHsExpr)]
+            [([RdrNameStmt], RdrNameHsExpr)]
             -- (guard,         expr)
             RdrBinding
 \end{code}