On Fri, Jan 2, 2009 at 9:21 PM, Miguel Mitrofanov <miguelim...@yandex.ru> wrote: > module Element where > import QName > import ... > data Element = Element {name :: QName, attribs :: [Attr], content :: > [Content], line :: Maybe Line} > > module Attr where > import QName > import ... > data Attr = Attr {key :: QName, val :: String} > > module QName where > import ... > data QName = QName {name :: String, uri :: Maybe String, prefix :: Maybe > String} > > module Main where > import qualified QName as Q > import qualified Element as E > ... Q.name ... E.name ...
I'm using this pattern of writing code and, so far, I find it very convenient. Yet, the code is likely to be spread across lots of files, which is not always a Good Thing. Cristiano _______________________________________________ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe