The Haskell Committee was well aware of the problem of name
capture in syntactic expansions.  We discussed various solutions
and opted for the simplest (if not most formal):  whenever a 

name freshly appears on the right side of a translation, add
a comment that says where it came from.  If you look at the
translations for expressions in Section 3 of the Report, you
will see many instances of the phrase "as defined in the Standard
Prelude".  It was an oversight not to include such a phrase in
the translation of patterns given in Section 3.14, the source of
Lennart's original question.

As for n+k patterns, I tried to get them out of Haskell on several
occasions, even before the Report was released, but failed!  Now
that I've programmed in Haskell for a few years, I'm convinced more
than ever that they should be removed.  So add me to the movement!

  -Paul
  

Reply via email to