Hans Aberg wrote:
On 19 Jul 2005, at 17:01, Evan Lavelle wrote:
The only way that I know a new function is coming up is that an
existing function has just completed: there's no convenient keyword
to give me warning. [If my grammar really was this simple, then I
could probably use another t
thanks fo your help...
Le mercredi 20 juillet 2005 à 10:34 +0200, Hans Aberg a écrit :
> On 20 Jul 2005, at 07:49, soledady wrote:
> >
> > can i construct a top-down grammar?
>
> It isn't the grammar that is top-down or not -- it is the parse tree
> that one build. The Bison generated parser b
On 20 Jul 2005, at 07:49, soledady wrote:
can i construct a top-down grammar?
It isn't the grammar that is top-down or not -- it is the parse tree
that one build. The Bison generated parser builds it bottom-up,
because Bison uses LALR(1). The other method is LL(k). In Bison, one
sometime
On 20 Jul 2005, at 09:21, Evan Lavelle wrote:
It seems me that you know that a function has been completed when
the function body top level "{" ... "}" has completed. This can
be kept track of by a bracket depth count in the lexer.
Unfortunately, the real grammar is much more complex
On Wed, 20 Jul 2005 10:34:25 +0200, Hans Aberg wrote
> You have to build a grammar. This is difficult at firts. The Bison
> manual has a calculator example. The book by Aho, Sethi, Ullman,
> "Compilers" (the "dragon book") has an example of using Lex and
> Yacc. Look in grammar-like BNF notat
On 20 Jul 2005, at 23:06, alfonso wrote:
This reminds me of a gripe I had when learning to use Bison (not
that I'm an
exper or anything, but I know enough to use it) - the calculator
example in
the docs is so trivial that it is completely worthless, and the
existing
language grammars such a