Peter Verswyvelen wrote: > I guess this is related to the expression problem. > Suppose I have a datatype > > *data Actor = Ball ... | Paddle ... | Wall ...* > > and a function > > *move (Ball ...) = * > *move (Paddle ...) = * > *move (Wall ...) = * > > in Haskell one must put *Actor* and *move* into a single file.
Just a nitpick: you don't have to put Actor and move into the same module. module A where data Actor = Ball | Paddle | Wall module B where import A (Actor) move Ball = ... move Paddle = ... move Wall = ... But that's probably not what you meant. Regards, apfelmus -- http://apfelmus.nfshost.com _______________________________________________ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe