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: g++ compile-time error with template arguments in 4.0 CVS?



On Feb 15, 2005, at 2:37 PM, Benjamin Redelings I wrote:


Hi,

I have a reduced testcase from BOOST that fails with yesterdays CVS (4.0.0 20050214 (experimental)), but compiles under 3.4. I don't know if this is a bug in BOOST or in g++:

------------------ begin testcase
template< typename T, T N >
struct integral_c
{
  static const T value = N;

  typedef integral_c< T, static_cast<T>((value + 1)) > next;
  //  typedef integral_c< T, static_cast<T>((value - 1)) > prior;

  //  operator T() const { return static_cast<T>(this->value); }
};
------------------- end testcase

This is related to PR 19883.


-- Pinski


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