This is the mail archive of the gcc-patches@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]
Other format: [Raw text]

Re: [PATCH 0/6] Convert gimple to a C++ class hierarchy


On Fri, Aug 30, 2013 at 11:37 AM, Jakub Jelinek <jakub@redhat.com> wrote:

> Teaching the gengtype parser about
> {struct,class} name : public {struct,class} someothername { ... }
> as opposed to current
> {struct,class} name { ... }
> shouldn't be that hard.  And, if the complaint is that we'd need to write
> whole C++ parser for it, then the response could be that we already have
> one C++ parser (and, even have plugin support and/or emit dwarf etc.).

It isn't.  It's annoying and a duplication of effort.

> So, gengtype could very well use a g++ plugin to emit the stuff it needs,
> or parse DWARF, etc.  And, we even could not require everybody actually
> emitting those themselves, we could check some text form of that
> (gengtype.state?) into the tree, so only people actually changing the
> compiler would need to run the plugin.

Yes.  Lawrence and I thought about moving gengtype inside g++.  That
seemed like a promising approach.

> Even if you have some stuff that helps you writing those, still it will be a
> big source of bugs (very hard to debug) and a maintainance nightmare.

Debugging gengtype is much harder.  It is magic code that is not visible.


Diego.


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