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: Invalid code in <limits>


On Wed, Jan 29, 2003 at 12:06:18AM -0800, Mark Mitchell wrote:
> The bottom line is that there's no need to make the compiler work
> hard to deal with this stuff; it's easy to make a keyword whose value
> is "__builtin_huge_valf () / 2 == __builtin_huge_valf ()" or
> "__builtin_nanf ("") != __builtin_nanf ("")"; you just evaluate that
> expression in the guts of the compiler where it can do whatever it
> wants.

Ok, but how about

	struct S {
	  static const double f = 1.0;
	  static const double g = __builtin_huge_valf ();
	};

(or whatever context is hardest for c++)?  If either
works, they should both work.


r~


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