[Haskell-beginners] Friend Modules?

John Smith voldermort at hotmail.com
Tue Nov 9 12:00:59 EST 2010

I have a module which defines data structures and their functions for a program. I have another module which defines 
show methods for the structures. Both modules have a substantial amount of code, and I would prefer to keep them 
separate. However, the show methods require access to internal data structures, which would not normally be exported. 
Furthermore, many modules do not require the show functions. Is there any solution to this, other than an intermediate 
module which imports the data module, and only exports the required names?

More information about the Beginners mailing list