expand advice on importing these modules
authorRoss Paterson <ross@soi.city.ac.uk>
Sun, 27 Aug 2006 16:40:44 +0000 (16:40 +0000)
committerRoss Paterson <ross@soi.city.ac.uk>
Sun, 27 Aug 2006 16:40:44 +0000 (16:40 +0000)
Data/IntMap.hs
Data/IntSet.hs
Data/Map.hs
Data/Set.hs

index e01e13b..e4377e5 100644 (file)
 --
 -- An efficient implementation of maps from integer keys to values.
 --
--- This module is intended to be imported @qualified@, to avoid name
--- clashes with "Prelude" functions.  eg.
+-- Since many function names (but not the type name) clash with
+-- "Prelude" names, this module is usually imported @qualified@, e.g.
 --
--- >  import Data.IntMap as Map
+-- >  import Data.IntMap (IntMap)
+-- >  import qualified Data.IntMap as IntMap
 --
 -- The implementation is based on /big-endian patricia trees/.  This data
 -- structure performs especially well on binary operations like 'union'
index b48a7c8..36cac36 100644 (file)
 --
 -- An efficient implementation of integer sets.
 --
--- This module is intended to be imported @qualified@, to avoid name
--- clashes with "Prelude" functions.  eg.
+-- Since many function names (but not the type name) clash with
+-- "Prelude" names, this module is usually imported @qualified@, e.g.
 --
--- >  import Data.IntSet as Set
+-- >  import Data.IntSet (IntSet)
+-- >  import qualified Data.IntSet as IntSet
 --
 -- The implementation is based on /big-endian patricia trees/.  This data
 -- structure performs especially well on binary operations like 'union'
index 56b25e1..da83cf2 100644 (file)
 --
 -- An efficient implementation of maps from keys to values (dictionaries).
 --
--- This module is intended to be imported @qualified@, to avoid name
--- clashes with Prelude functions.  eg.
+-- Since many function names (but not the type name) clash with
+-- "Prelude" names, this module is usually imported @qualified@, e.g.
 --
--- >  import Data.Map as Map
+-- >  import Data.Map (Map)
+-- >  import qualified Data.Map as Map
 --
 -- The implementation of 'Map' is based on /size balanced/ binary trees (or
 -- trees of /bounded balance/) as described by:
index fd80ca6..5f45ce9 100644 (file)
@@ -9,10 +9,11 @@
 --
 -- An efficient implementation of sets.
 --
--- This module is intended to be imported @qualified@, to avoid name
--- clashes with "Prelude" functions.  eg.
+-- Since many function names (but not the type name) clash with
+-- "Prelude" names, this module is usually imported @qualified@, e.g.
 --
--- >  import Data.Set as Set
+-- >  import Data.Set (Set)
+-- >  import qualified Data.Set as Set
 --
 -- The implementation of 'Set' is based on /size balanced/ binary trees (or
 -- trees of /bounded balance/) as described by: