[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Bison and $ (dollarsign) token at the end
From: |
Akim Demaille |
Subject: |
Re: Bison and $ (dollarsign) token at the end |
Date: |
09 Jul 2002 14:20:58 +0200 |
User-agent: |
Gnus/5.0808 (Gnus v5.8.8) XEmacs/21.4 (Honest Recruiter) |
>>>>> "Hans" == Hans Aberg <address@hidden> writes:
Hans> Here, "error" has a normal name, whereas there are two corny
Hans> names "$", "$undefined.". These names are not used for anything
Hans> but to write error messages.
And traces (YYDEBUG).
Hans> I think one could take some more descriptive, better looking,
Hans> userfriendly names, like "end-token" "undefined" "undefined
Hans> token"
Hm, I think the point of the $ business is to insist on the fact that
these are internal symbols, not reachable by the user: one cannot use
$ or $undefined in the grammar, while error is allowed.
Hans> Perhaps one should even have macros for these names (say
Hans> YYEND_TOKEN_NAME, YYUNDEFINED_TOKEN_NAME), so that they can be
Hans> changed at will.
This is already the case of $:
%token YYEOF 0 "end of file"
The question is really wrt the internal, out of user name space,
name.