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] Add gimple subclasses for every gimple code (was Re: [PATCH 0/6] Conversion of gimple types to C++ inheritance (v3))


Hi,

On Tue, 5 Nov 2013, David Malcolm wrote:

> Here's a followup patch which ensures that every gimple code has its own
> subclass, by adding empty subclasses derived from the GSS_-based
> subclasses as appropriate (I don't bother for gimple codes that already
> have their own subclass due to having their own GSS layout).  I also
> copied the comments from gimple.def into gimple.h, so that Doxygen picks
> up on the descriptions and uses them to describe each subclass.

I don't like that.  The empty classes are just useless, they imply a 
structure that isn't really there, some of the separate gimple codes are 
basically selectors of specific subtypes of a generic concept, without 
additional data or methods; creating a type for those is confusing.

Generally I don't like complicating the type system without good reasons 
(as in actually also making use of the complicated types).  The fewer 
types the better IMO.


Ciao,
Michael.


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