[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Bison 1.30f
From: |
Paul Eggert |
Subject: |
Re: Bison 1.30f |
Date: |
Mon, 17 Dec 2001 16:01:41 -0800 (PST) |
> Date: Sun, 16 Dec 2001 11:36:07 +0100
> From: Hans Aberg <address@hidden>
> first you said
> >Also, strictly speaking it is required for POSIX conformance.
> >POSIX 1003.1-2001 says:
> >
> > Conforming applications shall not use names beginning in yy or YY
> > since the yacc parser uses such names. Many of the names appear in the
> > final output of yacc, and thus they should be chosen to conform with
> > any additional rules created by the C compiler to be used. In
> > particular they appear in #define statements.
>
> and later you say:
>
> >> As for the real C++ support, I think that names yyfoo should become
> >> yy::foo, and YYFOO macro names should as far as possible be eliminated and
> >> replaced by yy C++ names. For example, in C++, one might replace
> >> # define help_key 258
> >> by
> >> const int help_key = 258;
> >> which would make use of fewer macros.
> >
> >For C, this would contradict the POSIX standard, which requires that
> >the symbols be visible to the preprocessor. It would also break some
> >real code.
I don't see why these two quotes are contradictory. The first quote
is about internal names in the generated code, which must begin with
yy or YY (in both C and C++, since they would otherwise run afoul of
preprocessor macros). The second quote is about names that are put
into y.tab.h; they aren't internal.
- Re: Bison 1.30f, (continued)
- Re: Bison 1.30f, Paul Eggert, 2001/12/14
- Re: Bison 1.30f, Hans Aberg, 2001/12/14
- Re: Bison 1.30f, Paul Eggert, 2001/12/14
- Re: Bison 1.30f, Hans Aberg, 2001/12/15
- Re: Bison 1.30f, Akim Demaille, 2001/12/15
- Re: Bison 1.30f, Hans Aberg, 2001/12/15
- Re: Bison 1.30f, Hans Aberg, 2001/12/15
- Re: Bison 1.30f, Paul Eggert, 2001/12/17
- Re: Bison 1.30f, Paul Eggert, 2001/12/16
- Re: Bison 1.30f, Hans Aberg, 2001/12/16
- Re: Bison 1.30f,
Paul Eggert <=
- Re: Bison 1.30f, Hans Aberg, 2001/12/18
- Re: Bison 1.30f, Paul Eggert, 2001/12/18
- Re: Bison 1.30f, Hans Aberg, 2001/12/19
- Re: Bison 1.30f, Paul Eggert, 2001/12/19
- Re: Bison 1.30f, Hans Aberg, 2001/12/20
- Re: Bison 1.30f, Magnus Fromreide, 2001/12/20
- Re: Bison 1.30f, Hans Aberg, 2001/12/21
- Re: Bison 1.30f, Magnus Fromreide, 2001/12/21
- Re: Bison 1.30f, Hans Aberg, 2001/12/21
- Re: Bison 1.30f, Paul Eggert, 2001/12/20