Renaming IS_AGGR_TYPE & co

Mark Mitchell mark@codesourcery.com
Wed Mar 12 01:09:00 GMT 2008


Paolo Carlini wrote:

> current is_aggr_type (would be is_class_type), beyond MAYBE_CLASS_TYPE_P 
> emits *error messages*, which currently wrongly talk about 
> ""aggregate"". 

Good catch.

> I understand that in this case only in order to preserve 
> and improve the current behavior I should open code a check of 
> MAYBE_CLASS_TYPE_P and an error message talking about... what?!?... just 
> "class type" would be Ok for the error message?

Yes, I think something like:

   "%T is not a class type", base

would be good.  If it's not MAYBE_CLASS_TYPE_P then it's certainly not a 
class, so this is an accurate error message, and it's makes clear what 
the problem is: base classes have to be *classes*.

Thanks,

-- 
Mark Mitchell
CodeSourcery
mark@codesourcery.com
(650) 331-3385 x713



More information about the Gcc-patches mailing list