Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo

Close

#56 let-match does not work as documented

closed-fixed
Olin Shivers
5
2003-01-23
2001-07-17
Michel Schinz
No

The example for the let-match function (p. 134 of the
scsh manual) is:

(let-match (regexp-search date s)
(whole-date month day year)
... body ...)

and the documentation claims that this "evaluates the
body of the let-match in a scope where whole-date is
bound to the matched string, and month, day and year
are bound to the first, second and third submatches."

However, let-match does not behave like that in 0.5.3:
the first variable is bound to the *match record* (not
the matched string as is claimed), the second to the
whole string and the next ones to the successive
sub-matches.

Therefore the documentation or the code should be fixed
so that both agree.

(Notice that if-match transitively suffers from the
same problem).

Thanks.
Michel.

Discussion

  • Mike Sperber
    Mike Sperber
    2002-12-17

    Logged In: YES
    user_id=43931

    I've decided to make the implementation conform to the
    documentation for 0.6.3.

     
  • Mike Sperber
    Mike Sperber
    2002-12-17

    • status: open --> open-fixed
     
    • status: open-fixed --> closed-fixed