[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Another - Bison 1.35 works but Bison 1.50 Doesn't
From: |
Paul Eggert |
Subject: |
Re: Another - Bison 1.35 works but Bison 1.50 Doesn't |
Date: |
Mon, 14 Oct 2002 02:02:10 -0700 (PDT) |
> From: Akim Demaille <address@hidden>
> Date: 14 Oct 2002 10:39:15 +0200
>
> I was thinking that the default action could be really implemented as
> a default action (a default: in the switch, or even an explicit action
> per missing case:), not as a pre-action. In languages which are more
> properly type checked than C, our trick of typelessly pre-storing $1
> in $$ is not a good thing TM.
True.
> So I was thinking that having the user make explicit what they want is
> a better options.
But this doesn't follow. If the Bison user doesn't specify any
action, and if $$ is untyped but $1 is typed, then the user can't make
use of the default action's side effects, so the default action is
functionally equivalent to {} in this case. So it is purely a
notational convenience that the user doesn't need to explicitly say
"{}" in this case. Bison can implement it the same, regardless of
whether the user explicitly says "{}".
This is similar to the "(void) close (0);" statement in C: the
"(void)" doesn't need to alter the code that gets generated, since the
C program has the same meaning if the "(void)" is omitted.
- Re: Another - Bison 1.35 works but Bison 1.50 Doesn't, (continued)
- Re: Another - Bison 1.35 works but Bison 1.50 Doesn't, Akim Demaille, 2002/10/13
- Re: Another - Bison 1.35 works but Bison 1.50 Doesn't, Paul Eggert, 2002/10/13
- Re: Another - Bison 1.35 works but Bison 1.50 Doesn't, Akim Demaille, 2002/10/13
- Re: Another - Bison 1.35 works but Bison 1.50 Doesn't, Paul Eggert, 2002/10/14
- Re: Another - Bison 1.35 works but Bison 1.50 Doesn't, Tim Van Holder, 2002/10/14
- Re: Another - Bison 1.35 works but Bison 1.50 Doesn't, Paul Eggert, 2002/10/14
- Re: Another - Bison 1.35 works but Bison 1.50 Doesn't, Tim Van Holder, 2002/10/14
- Re: Another - Bison 1.35 works but Bison 1.50 Doesn't, Akim Demaille, 2002/10/14
- Re: Another - Bison 1.35 works but Bison 1.50 Doesn't, Akim Demaille, 2002/10/14
- Re: Another - Bison 1.35 works but Bison 1.50 Doesn't, Akim Demaille, 2002/10/14
- Re: Another - Bison 1.35 works but Bison 1.50 Doesn't,
Paul Eggert <=
- Re: Another - Bison 1.35 works but Bison 1.50 Doesn't, Akim Demaille, 2002/10/14