[Haskell-cafe] Re: Haskell and qualified identifiers

Henning Thielemann iakd0 at clusterf.urz.uni-halle.de
Wed Dec 8 13:06:55 EST 2004


On Wed, 8 Dec 2004, Duncan Coutts wrote:

> I use HashTable like so:
> 
> import Data.HashTable (HashTable)
> import qualified Data.HashTable as HashTable

If you give a generic name for the type, you can leave out the first
'import' and can stick completely to qualified identifiers, like
HashTable.T. This makes also clear that the module name should match the
data type described in the module (particularly in singular form), and
that each module should handle only one (essential) data type.



More information about the Haskell-Cafe mailing list