diff options
author | Max Bolingbroke <batterseapower@hotmail.com> | 2008-08-07 22:43:33 +0000 |
---|---|---|
committer | Max Bolingbroke <batterseapower@hotmail.com> | 2008-08-07 22:43:33 +0000 |
commit | 393f26621b762225b204b3dc78b05a3ecf08871e (patch) | |
tree | 291f5d142d14413ff82e07d10b14163afc7a8b00 /compiler/deSugar | |
parent | 2e06595241350a6548b6ab6430c65d6458f7c197 (diff) | |
download | haskell-393f26621b762225b204b3dc78b05a3ecf08871e.tar.gz |
Remove redundant fromIntegral calls
Diffstat (limited to 'compiler/deSugar')
-rw-r--r-- | compiler/deSugar/DsMeta.hs | 4 | ||||
-rw-r--r-- | compiler/deSugar/MatchLit.lhs | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/compiler/deSugar/DsMeta.hs b/compiler/deSugar/DsMeta.hs index 6cc1eee313..3659498eec 100644 --- a/compiler/deSugar/DsMeta.hs +++ b/compiler/deSugar/DsMeta.hs @@ -1250,7 +1250,7 @@ repNamedTyCon (MkC s) = rep2 conTName [s] repTupleTyCon :: Int -> DsM (Core TH.TypeQ) -- Note: not Core Int; it's easier to be direct here -repTupleTyCon i = rep2 tupleTName [mkIntExpr (fromIntegral i)] +repTupleTyCon i = rep2 tupleTName [mkIntExprInt i] repArrowTyCon :: DsM (Core TH.TypeQ) repArrowTyCon = rep2 arrowTName [] @@ -1345,7 +1345,7 @@ coreStringLit :: String -> DsM (Core String) coreStringLit s = do { z <- mkStringExpr s; return(MkC z) } coreIntLit :: Int -> DsM (Core Int) -coreIntLit i = return (MkC (mkIntExpr (fromIntegral i))) +coreIntLit i = return (MkC (mkIntExprInt i)) coreVar :: Id -> Core TH.Name -- The Id has type Name coreVar id = MkC (Var id) diff --git a/compiler/deSugar/MatchLit.lhs b/compiler/deSugar/MatchLit.lhs index b6079d31b1..5e30f32778 100644 --- a/compiler/deSugar/MatchLit.lhs +++ b/compiler/deSugar/MatchLit.lhs @@ -72,7 +72,7 @@ dsLit (HsDoublePrim d) = return (Lit (MachDouble d)) dsLit (HsChar c) = return (mkCharExpr c) dsLit (HsString str) = mkStringExprFS str dsLit (HsInteger i _) = mkIntegerExpr i -dsLit (HsInt i) = return (mkIntExpr (fromIntegral i)) +dsLit (HsInt i) = return (mkIntExpr i) dsLit (HsRat r ty) = do num <- mkIntegerExpr (numerator r) |