[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: proposal: simplify prologue alternatives into %code
From: |
Hans Aberg |
Subject: |
Re: proposal: simplify prologue alternatives into %code |
Date: |
Tue, 9 Jan 2007 15:35:57 +0100 |
On 9 Jan 2007, at 15:10, Paolo Bonzini wrote:
The changes are small. But on should also keep the door for other
langauge than C/C++/Java.
Keeping the door open, yes. But not at the cost of complicating
needlessly what already exists now.
Keeping things well structured avoids that.
I'm also against a new directive such as your %cast, since Bison
already has too many and -- in this particular case -- a simple %
define is all that is needed.
Well, it is a fundamental feature of Bison that needs to be
expanded. So one adds commands to help the user. If, in principle,
all commands could be replaced by %define, woud you want to use it?
Yes.
That is not a principle of ordinary computer language design, then.
I mean, "%union" or "%initial-action" could be replaced by "%code",
and so could many other commands. Not "%left" and friends, for sure.
Well, %union can't be changed because of legacy (and compatibility
with POSIX, I gather).
If you look back, I suggested %code should introduced for code
placements instead of %define, to help up the users, and unifying
different such code placements into one. And Bison development is now
moving along that path.
The trick is to keep things structured. Those features that are
related, should one attempt to unify. Others: keep separate.
Hans Aberg
- Re: [SPAM] Re: proposal: simplify prologue alternatives into %code, (continued)
Re: proposal: simplify prologue alternatives into %code, Hans Aberg, 2007/01/09
Re: proposal: simplify prologue alternatives into %code, Hans Aberg, 2007/01/09
Re: proposal: simplify prologue alternatives into %code, Paolo Bonzini, 2007/01/09
Re: proposal: simplify prologue alternatives into %code, Hans Aberg, 2007/01/09
Re: proposal: simplify prologue alternatives into %code, Paolo Bonzini, 2007/01/09
Re: proposal: simplify prologue alternatives into %code, Hans Aberg, 2007/01/09