Chris Okasaki writes:
 > >    Empty values of type X have the name emptyX, e.g. emptySet.
 > 
 > You've struck a pet peeve of mine.  These suffixes are doing namespace
 > management, avoiding name clashes between different things that you
 > want to call empty.  But Haskell already has a perfectly good language
 > mechanism for doing this -- the module system!

I agree with Chris for all the reasons he's stated. I've argued for more
ubiquitous use of the qualified name syntax on several occasions myself.

 > If anybody has a good argument against using the module system in
 > this context, I would very much like to hear it, because I use the
 > module-based convention almost exclusively in Edison.

To be fair, I can give 4 arguments against it.

  1) Hugs's error messages don't qualify names, so they become very difficult
     to read when you use this convention.

  2) The Prelude doesn't use it.

  3) Nobody else uses it either, except me (and Chris, apparently :).

  4) Qualified infix operators are ugly.

#2-#4 are basically aesthetic. #1 is the least important in theory, since it's
fixable and implementation-dependent, but turned out for me to be the most
important in practice; Hugs' atrocious behavior on this score has caused me to
disregard my own better judgement here for serious projects. I guess it will
become a non-issue soon, though, with Hugs passing on...

-- 
Frank Atanassow, Dept. of Computer Science, Utrecht University
Padualaan 14, PO Box 80.089, 3508 TB Utrecht, Netherlands
Tel +31 (030) 253-1012, Fax +31 (030) 251-3791


Reply via email to