summaryrefslogtreecommitdiff
path: root/libraries
diff options
context:
space:
mode:
authorJan Stolarek <jan.stolarek@p.lodz.pl>2013-09-16 15:17:09 +0100
committerJan Stolarek <jan.stolarek@p.lodz.pl>2013-09-18 11:45:39 +0100
commit937fab753881c8d8b96d899f955cc9fc75401622 (patch)
tree371d27ba1a523d49fe446d236121d212ba9f3f8c /libraries
parent2c2ead5a2ee628559044497fe6584831cf978172 (diff)
downloadhaskell-937fab753881c8d8b96d899f955cc9fc75401622.tar.gz
Follow changes in comparison primops (see #6135)
Diffstat (limited to 'libraries')
-rw-r--r--libraries/template-haskell/Language/Haskell/TH/Syntax.hs17
1 files changed, 8 insertions, 9 deletions
diff --git a/libraries/template-haskell/Language/Haskell/TH/Syntax.hs b/libraries/template-haskell/Language/Haskell/TH/Syntax.hs
index 545757ff6f..d59fffff6b 100644
--- a/libraries/template-haskell/Language/Haskell/TH/Syntax.hs
+++ b/libraries/template-haskell/Language/Haskell/TH/Syntax.hs
@@ -16,8 +16,7 @@
module Language.Haskell.TH.Syntax where
-import GHC.Base ( Int(..), Int#, (<#), (==#) )
-
+import GHC.Exts
import Data.Data (Data(..), Typeable, mkConstr, mkDataType, constrIndex)
import qualified Data.Data as Data
import Control.Applicative( Applicative(..) )
@@ -722,22 +721,22 @@ instance Ord NameFlavour where
(NameU _) `compare` NameS = GT
(NameU _) `compare` (NameQ _) = GT
- (NameU u1) `compare` (NameU u2) | u1 <# u2 = LT
- | u1 ==# u2 = EQ
- | otherwise = GT
+ (NameU u1) `compare` (NameU u2) | isTrue# (u1 <# u2) = LT
+ | isTrue# (u1 ==# u2) = EQ
+ | otherwise = GT
(NameU _) `compare` _ = LT
(NameL _) `compare` NameS = GT
(NameL _) `compare` (NameQ _) = GT
(NameL _) `compare` (NameU _) = GT
- (NameL u1) `compare` (NameL u2) | u1 <# u2 = LT
- | u1 ==# u2 = EQ
- | otherwise = GT
+ (NameL u1) `compare` (NameL u2) | isTrue# (u1 <# u2) = LT
+ | isTrue# (u1 ==# u2) = EQ
+ | otherwise = GT
(NameL _) `compare` _ = LT
(NameG ns1 p1 m1) `compare` (NameG ns2 p2 m2) = (ns1 `compare` ns2) `thenCmp`
(p1 `compare` p2) `thenCmp`
- (m1 `compare` m2)
+ (m1 `compare` m2)
(NameG _ _ _) `compare` _ = GT
data NameIs = Alone | Applied | Infix