Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Fix defaulting to type integer

  • Loading branch information...
commit f711d09729e9388dc21af7cab9a4219df2f118cc 1 parent 1fb7f46
Gregory Collins authored
Showing with 4 additions and 4 deletions.
  1. +4 −4 src/Data/HashTable/Internal/CacheLine.hs
8 src/Data/HashTable/Internal/CacheLine.hs
View
@@ -234,11 +234,11 @@ prefetchWrite _ _ = return ()
{-# INLINE forwardSearch2 #-}
forwardSearch2 :: IntArray s -> Int -> Int -> Int -> Int -> ST s Int
-forwardSearch2 !vec !start !end !x1 !x2 = go start end 0
+forwardSearch2 !vec !start !end !x1 !x2 = go start end False
where
next !i !e !b = let !j = i+1
in if j == e
- then (if b > 0 then (-1,e,1) else (0,start,1))
+ then (if b then (-1,e,True) else (0,start,True))
else (j,e,b)
go !i !e !b = do
@@ -252,11 +252,11 @@ forwardSearch2 !vec !start !end !x1 !x2 = go start end 0
{-# INLINE forwardSearch3 #-}
forwardSearch3 :: IntArray s -> Int -> Int -> Int -> Int -> Int -> ST s Int
-forwardSearch3 !vec !start !end !x1 !x2 !x3 = go start end 0
+forwardSearch3 !vec !start !end !x1 !x2 !x3 = go start end False
where
next !i !e !b = let !j = i+1
in if j == e
- then (if b > 0 then (-1,e,1) else (0,start,1))
+ then (if b then (-1,e,True) else (0,start,True))
else (j,e,b)
go !i !e !b = do
Please sign in to comment.
Something went wrong with that request. Please try again.