help-bison
[Top][All Lists]
Advanced

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

Re: language neutral parser


From: Pinku Surana
Subject: Re: language neutral parser
Date: Fri, 19 Oct 2001 19:08:53 -0500

If you think this would be a good idea, then I'd like your estimate of how
much work it would be to add this option to bison. The only moderately hard
part is writing a good XML Schema definition that lends itself to easy
manipulation by XSL transform rules.

bison --xml grammar.y

Produce the following in an XML file:
    all #DEFINE for tokens
    all yy* arrays
    all actions, in any language, mapped to the correct "yyn" token (like
the .act file now)
    all additional code (C decl section and code after the last %%)

If you think the backend could be written without much trouble, I would be
willing to write the code to translate everything to XML, but I would need
help from someone who knows the bison code base to help glue everything
together.

Pinku




----- Original Message -----
From: "Pascal Bart" <address@hidden>
To: "Axel Kittenberger" <address@hidden>
Cc: "Pinku Surana" <address@hidden>; "Help Bison"
<address@hidden>
Sent: Friday, October 19, 2001 7:34 PM
Subject: Re: language neutral parser


> Hello,
>
> >Not true, the parser tables are they are generated are C code, yes C++
can
> >use it, since C++ is backward compatible to C. But for any othe language
you
> >have to modifiy the bison binary itself to generate the tables in another
> >way.
>
> I'm agree, tables and actioner (goto, switch) are always generated by
> bison binary. But this is a first step, C, C++, java and perl could have
> their own skeleton without change bison.
>
> >I find the idea to use XML as intermetiate genial, something I woult not
put
> >into a drawer too soon.
>
> Yes, bison will change in this way.  In fact, we work on generation of
> intermediate step.
>
> >But again this appeals to something I asked already before. What is
really
> >the exacter mission of the official bison project?
>
> Good question ;)
>
> >Just tinker in the old source somewhat, here and there? Create a C parser
> >generator only? Maybe now a bit C++ also. Be an universal parser
generator?
>
> Every night, I dream about bison, which becomes an universal parser
> generator. But for the moment, this is just a dream.
>
> >Maybe help and encourage to develop new parser technologies? In addition
to
> >the difference of usual make the results available public. I guess there
are
> >dozends of better parser generators, but all closed source, or company
intern
> >after all.
>
> Bison should generate parser wrotten with differents language, it should
> use other parser like DRLR, it should use a better error recovery, sources
> should be cleaner, ...
>
> >I agree that today most main stream languages have their own generator.
But
> >this is in my eyes just an execuse, and an additional burden each
language
> >has to go through. I blieve the "(world) community" would really benefit
of
> >an universal GNU parser generator.
>
> I'm agree. :)
>
> Pascal Bart (address@hidden)
>




reply via email to

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