bug-bison
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Bug in demonstration code in texinfo documentation.


From: Scott A Crosby
Subject: Re: Bug in demonstration code in texinfo documentation.
Date: 23 Sep 2003 17:47:35 -0500
User-agent: Gnus/5.0808 (Gnus v5.8.8) XEmacs/21.4 (Common Lisp)

On 23 Sep 2003 13:15:41 -0500, Scott A Crosby <address@hidden> writes:

> On 23 Sep 2003 09:48:16 -0700, Paul Eggert <address@hidden> writes:
> 

>           for (i = 0; i < YYNTOKENS; i++)

Another bug here: YYNTOKENS doesn't actually exist with visability at
this point. Thus this code doesn't compile.

  for (i = 0; yytname[i]; i++)

I think is what is needed (untested however.)

>             {
>               if (yytname[i] != 0
>                   && yytname[i][0] == '"'
>                   && ! strncmp (yytname[i] + 1, token_buffer,
>                                 strlen (token_buffer))
>                   && yytname[i][strlen (token_buffer) + 1] == '"'
>                   && yytname[i][strlen (token_buffer) + 2] == 0)
>                 break;
>             }
> 

Scott




reply via email to

[Prev in Thread] Current Thread [Next in Thread]