[Top][All Lists]

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

Re: %destructor feedback

From: Paul Eggert
Subject: Re: %destructor feedback
Date: Thu, 20 Oct 2005 13:26:31 -0700
User-agent: Gnus/5.1007 (Gnus v5.10.7) Emacs/21.4 (gnu/linux)

"Joel E. Denny" <address@hidden> writes:

> Paul, I just looked through the ChangeLog.  I believe you committed
> the patch that made YYABORT and YYACCEPT invoke RHS destructors.

Yes, I'm the guilty party.  :-)  I hadn't thought through these

> As I see it, there would be one rule at first: in all cases (usual
> success, YYACCEPT, YYABORT, or YYERROR), the user must clean up RHS
> semantic values in any semantic action he provides.
> Then there's the automatic destructor calls for unmentioned RHS
> semantic values.  This feature is proposed in the bison documentation.
> If this feature is added, the user could avoid writing the destructor
> invocation for a particular RHS semantic value by simply not
> mentioning that semantic value in the semantic action.  You seem to be
> agreeing to this feature for the case of YYABORT and YYERROR in your
> first response quoted above.

Yes, I just didn't get the connection.  I assumed you were proposing
to modify the "one rule at first" with a special case for
YYABORT/YYERROR.  But instead, you were saying "let's add a special
case for unmentioned RHS semantic values", and saying that that solves
the YYABORT/YYERROR case.  I agree with the latter special case, yes.

> Please note that, later in this thread, Wolfgang and I pointed out a
> number of potential problems with this proposed unmentioned RHS
> semantic value feature.  I wonder if it should be reconsidered.

I must have missed those messages, or at least not understood them.
The only message I got from Wolfgang was
is that what you're referring to?

reply via email to

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