Implementation of <tgmath.h>

Joern Rennecke amylaar@cygnus.co.uk
Fri Jul 28 15:12:00 GMT 2000


> Geoff Keating <geoffk@cygnus.com> writes:
> 
> > There is, or used to be, a '__builtin_classify_type' builtin that
> > might be helpful here.
> 
> No, this does not work.

Why not?  You could check for real_type_class, and if it is, you use the
sizeof tests.

Another approach would be to cast 0.25 to the argument type, and test if
that's non-zero.  If so, we are dealing with a floating point type.


More information about the Libc-alpha mailing list