Ticket #38 (new enhancement)

Opened 7 years ago

Create user defined data sturcture as instance of Elem

Reported by: fxie Owned by: chak
Priority: major Milestone:
Component: Accelerate language Version:
Keywords: Cc:


Hi, I'm trying to use accelerate to write multipole solver using CUDA as backend.

I wanted to create user defined data structure like:

data Panel b a
     = Panel { getBounds    :: b
             , getSrcBounds :: (Int, Int)
             -- , getFarExpan  :: Array Int a
       deriving (Show, Typeable)

But I found that it's hard to declare it as an instance of `Elem' because its methods are hidden.

I understand that user can define a type using nested (,). But it would be nice to expose Elem' to end user so user can use any type as Elem'. Is there any concern about this?

Note: See TracTickets for help on using tickets.