Commit 5601845d authored by chak@cse.unsw.edu.au.'s avatar chak@cse.unsw.edu.au.
Browse files

Adapt 'dph-classes' to class support in dph-lifted-vseg

parent 0a797ea3
......@@ -4,26 +4,12 @@
module DefsVect where
import Data.Array.Parallel
import Data.Array.Parallel.Prelude.Bool
import Data.Array.Parallel.Prelude.Int (Int, sumP)
{-# VECTORISE class Eq #-}
{-# VECTORISE SCALAR instance Eq Bool #-}
-- {-# VECTORISE SCALAR instance Eq Char #-}
{-# VECTORISE SCALAR instance Eq Int #-}
{-# VECTORISE SCALAR instance Eq Word8 #-}
-- {-# VECTORISE SCALAR instance Eq Float #-}
{-# VECTORISE SCALAR instance Eq Double #-}
{-# VECTORISE SCALAR instance Eq Ordering #-}
{-# VECTORISE class Ord #-}
{-# VECTORISE SCALAR instance Ord Bool #-}
-- {-# VECTORISE SCALAR instance Ord Char #-}
{-# VECTORISE SCALAR instance Ord Int #-}
{-# VECTORISE SCALAR instance Ord Word8 #-}
-- {-# VECTORISE SCALAR instance Ord Float #-}
{-# VECTORISE SCALAR instance Ord Double #-}
{-# VECTORISE SCALAR instance Ord Ordering #-}
data MyBool = MyTrue | MyFalse
......@@ -31,6 +17,11 @@ data MyBool = MyTrue | MyFalse
class Eq a => Cmp a where
cmp :: a -> a -> Bool
-- FIXME:
-- instance Cmp Int where
-- cmp = (==)
-- isFive :: (Eq a, Num a) => a -> Bool
isFive :: Int -> Bool
isFive x = x == 5
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment