This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: C/C++ front-end extension a la SWIG?


>>>>> "Martin" == Martin v Loewis <martin@loewis.home.cs.tu-berlin.de> writes:

    >> does this make sense?

    Martin> In my opinion, separating the C++ front-end from gcc is
    Martin> pointless. What you get is more or less the parser, and
    Martin> the g++ parser is not something you want to use unless you
    Martin> really have to. There are a number of other good C++
    Martin> parsers - I'd consider those first if I needed one for a
    Martin> project.

I rather strongly disagree -- at least if we're talking about the
future.

The G++ parser will always be very useful for one thing: parsing the
code the same way that G++ does.  For example, one can imagine hooking
it into GDB so that you could type C++ expressions at GDB for
interpretation; GDB would use the G++ front-end to parse the
expression, and then interpret the tree structure.  A source-browser
designed to work with G++ could use the G++ parser, and be sure to
handle G++ extensions and bugs just like G++.

As the parser itself (in the sense of the bison bits) are replaced
(and they will be, they will be) then this will become even more
useful.

There is no reason the G++ front-end cannot be as useful in the free
software community as the EDG front-end has been in other communities,
for example.

--
Mark Mitchell                   mark@codesourcery.com
CodeSourcery, LLC               http://www.codesourcery.com

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]