Major clean-up of HscMain.
[ghc-hetmet.git] / compiler / cmm / MachOp.hs
index 10cc0cd..422ed5e 100644 (file)
@@ -90,6 +90,7 @@ module MachOp         (
 
 import Constants
 import Outputable
 
 import Constants
 import Outputable
+import FastString
 
 -- -----------------------------------------------------------------------------
 -- MachRep
 
 -- -----------------------------------------------------------------------------
 -- MachRep
@@ -125,14 +126,14 @@ data MachRep
   | F80                -- extended double-precision, used in x86 native codegen only.
   deriving (Eq, Ord, Show)
 
   | F80                -- extended double-precision, used in x86 native codegen only.
   deriving (Eq, Ord, Show)
 
-mrStr I8   = SLIT("I8")
-mrStr I16  = SLIT("I16")
-mrStr I32  = SLIT("I32")
-mrStr I64  = SLIT("I64")
-mrStr I128 = SLIT("I128")
-mrStr F32  = SLIT("F32")
-mrStr F64  = SLIT("F64")
-mrStr F80  = SLIT("F80")
+mrStr I8   = sLit "I8"
+mrStr I16  = sLit "I16"
+mrStr I32  = sLit "I32"
+mrStr I64  = sLit "I64"
+mrStr I128 = sLit "I128"
+mrStr F32  = sLit "F32"
+mrStr F64  = sLit "F64"
+mrStr F80  = sLit "F80"
 
 instance Outputable MachRep where
    ppr rep = ptext (mrStr rep)
 
 instance Outputable MachRep where
    ppr rep = ptext (mrStr rep)
@@ -283,10 +284,10 @@ data MachHint
   | FloatHint
   deriving Eq
 
   | FloatHint
   deriving Eq
 
-mhStr NoHint     = SLIT("NoHint")
-mhStr PtrHint    = SLIT("PtrHint")
-mhStr SignedHint = SLIT("SignedHint")
-mhStr FloatHint  = SLIT("FloatHint")
+mhStr NoHint     = sLit "NoHint"
+mhStr PtrHint    = sLit "PtrHint"
+mhStr SignedHint = sLit "SignedHint"
+mhStr FloatHint  = sLit "FloatHint"
 
 instance Outputable MachHint where
    ppr hint = ptext (mhStr hint)
 
 instance Outputable MachHint where
    ppr hint = ptext (mhStr hint)
@@ -479,10 +480,10 @@ cLongRep = I64
 -- isCommutableMachOp
 
 {- |
 -- isCommutableMachOp
 
 {- |
-Returns 'True' if the MachOp has commutable arguments.  This is used
+Returns @True@ if the MachOp has commutable arguments.  This is used
 in the platform-independent Cmm optimisations.
 
 in the platform-independent Cmm optimisations.
 
-If in doubt, return 'False'.  This generates worse code on the
+If in doubt, return @False@.  This generates worse code on the
 native routes, but is otherwise harmless.
 -}
 isCommutableMachOp :: MachOp -> Bool
 native routes, but is otherwise harmless.
 -}
 isCommutableMachOp :: MachOp -> Bool
@@ -503,10 +504,10 @@ isCommutableMachOp mop =
 -- isAssociativeMachOp
 
 {- |
 -- isAssociativeMachOp
 
 {- |
-Returns 'True' if the MachOp is associative (i.e. @(x+y)+z == x+(y+z)@)
+Returns @True@ if the MachOp is associative (i.e. @(x+y)+z == x+(y+z)@)
 This is used in the platform-independent Cmm optimisations.
 
 This is used in the platform-independent Cmm optimisations.
 
-If in doubt, return 'False'.  This generates worse code on the
+If in doubt, return @False@.  This generates worse code on the
 native routes, but is otherwise harmless.
 -}
 isAssociativeMachOp :: MachOp -> Bool
 native routes, but is otherwise harmless.
 -}
 isAssociativeMachOp :: MachOp -> Bool
@@ -523,7 +524,7 @@ isAssociativeMachOp mop =
 -- isComparisonMachOp
 
 {- | 
 -- isComparisonMachOp
 
 {- | 
-Returns 'True' if the MachOp is a comparison.
+Returns @True@ if the MachOp is a comparison.
 
 If in doubt, return False.  This generates worse code on the
 native routes, but is otherwise harmless.
 
 If in doubt, return False.  This generates worse code on the
 native routes, but is otherwise harmless.