This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: [RFC] type safe trees
- From: Nathan Sidwell <nathan at codesourcery dot com>
- To: Paolo Bonzini <bonzini at gnu dot org>
- Cc: gcc at gcc dot gnu dot org, zack at codesourcery dot com
- Date: Wed, 23 Jun 2004 15:59:56 +0100
- Subject: Re: [RFC] type safe trees
- Organization: CodeSourcery LLC
- References: <40D994BE.3080208@codesourcery.com> <40D998D5.3050401@gnu.org>
Paolo Bonzini wrote:
#else
#include "expr_t.h"
#endif
Why not feeding gengtype with the classes only, and have it produce a
file with all the #include directives?
gengtype already scans all of the source to do its GTY magic. The idea of
defining the nodes inline like this appeals to me more than having them off
in some meta file elsewhere. If we do that, it is natural to make the
generated C have the same scope and lifetime as the original class
declaration. That way you know exactly where and when you can use the
generated macros and structs.
nathan
--
Nathan Sidwell :: http://www.codesourcery.com :: CodeSourcery LLC
nathan@codesourcery.com :: http://www.planetfall.pwp.blueyonder.co.uk