Re: Error in the SRFI-30 formal specification Almanac Petrofsky 12 Jan 2003 06:42 UTC

I wrote:

> I think the way to write the specification you intended is like this:
>
>   <comment> ---> ; <all subsequent characters up to a line break>
>                | <srfi-30-comment>
>
>   <srfi-30-comment> #| <comment-text> (<srfi-30-comment> <comment-text>)* |#
>
>   <comment-text> ---> <character sequence not containing #| or |#>

Actually, I think "the way" would be more like this:

  <comment> ---> ; <all subsequent characters up to a line break>
               | <srfi-30-comment>

  <srfi-30-comment> ---> #| <srfi-30-comment-body>* |#

  <srfi-30-comment-body> ---> <character sequence not containing #| or |#>
                            | <srfi-30-comment>

That eliminates the lopsidedness of srfi-30-comment, and also
eliminates the confusing use of parentheses to indicate a BNF grouping
rather than parentheses tokens (which is what they mean throughout
r5rs 7.1).

-al