[Haskell-cafe] APIs (was: Unexported functions are evil)

Graham Klyne GK at ninebynine.org
Tue May 31 12:00:00 EDT 2005

At 17:20 19/05/05 -0400, ajb at spamcop.net wrote:
> > One of the best bad example is the use of boolean as arguments.
>Oh, yes.  That's a pet peeve of mine.  About 99% of boolean arguments
>should be meaningful two-valued enumerated types.  It's literally a
>one-liner to create such an enumerated type, so there's no excuse.

While I see your point in the case of Booleans, I note that, in other 
circumstances, not using a pre-existing data type can be sub-optimal;  cf. 
use of Maybe noted at [1].



Graham Klyne
For email:

More information about the Haskell-Cafe mailing list