help-bison
[Top][All Lists]
Advanced

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

Re: %destructor questions


From: Akim Demaille
Subject: Re: %destructor questions
Date: Mon, 25 Oct 2004 17:59:13 +0200
User-agent: Gnus/5.1006 (Gnus v5.10.6) Emacs/21.3 (gnu/linux)

>>> "Bill" == Bill Fenlason <address@hidden> writes:

 > Finally (and most important), is there a way to specify a user
 > version of yydestruct?  Or at least the default case of the switch
 > statement?

 > The problem is that with the current syntax, %destructor statements
 > with well over a thousand names must be coded - not a small task in
 > itself.  But worse, a huge, unnecessary switch statement will be
 > generated, and over a thousand copies of the same destructor code
 > will be generated and compiled.

Actually, in a better world they would all be factored behind a huge
switch.  The code would be emitted only once.  Currently it is not
possible, nor high priority, but it should be included eventually.

 > One simple solution might be to allow a %destructor statement
 > without any symbols, and use the provided code as the switch
 > default.

That sounds reasonable, indeed.




reply via email to

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