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]

Re: Need someone to look at a regression


>>>>> Jeffrey A Law <law@cygnus.com> writes:

 >   In message <r2ww8bx9uq.fsf@happy.cygnus.com>you write:
 >> law@cygnus.com (Jeffrey A Law) writes:
 >> 
 >> >    typedef SFtype __attribute__ ((mode (SF)));
 >> > 
 >> > We have an explicit type (SFmode), why in the hell would we ever
 >> > want/need typedef int ....?
 >> 
 >> Isn't it that the __attribute__ stuff is, well, an attribute and it
 >> should be possible to drop it?  Then yu would get
 >> 
 >> 	typedef SFtype;
 >> 
 >> which clearly is wrong.  You simply cannot leave out the base type.

 > I don't see that the "int" is a base type in this case.  How can you
 > have an integer base type for a floating point mode?

In C,

  typedef SFtype;

is equivalent to

  typedef int SFtype;

by the implicit int rule.  In C++ and C9X, there is no such rule, so the
above is ill-formed.

Jason


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