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]
Other format: [Raw text]

Re: Putting C++ code into gcc front end


Neil Booth wrote:
Really, why does everything have to be shoehorned into being a tree?
Decls, expressions, scopes / symbol tables, statements etc should
all be their own data type.  We can get perfectly good type checking
in C if we don't insist the universe is made up of trees.

I agree. However, inheritance is still useful. For example one might have different classes for different kinds of declarations, different kinds of expressions, etc. Perhaps not that big a benefit.

Even more valuable: C++ constructors, destructors, and assignment
operators might have reduced the need for garbage collection.
--
	--Per Bothner
per at bothner dot com   http://www.bothner.com/per/


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