*** UNIX MANUAL PAGE BROWSER ***

A Nergahak database for man pages research.

Navigation

Directory Browser

1Browse 4.4BSD4.4BSD
1Browse Digital UNIXDigital UNIX 4.0e
1Browse FreeBSDFreeBSD 14.3
1Browse MINIXMINIX 3.4.0rc6-d5e4fc0
1Browse NetBSDNetBSD 10.1
1Browse OpenBSDOpenBSD 7.7
1Browse UNIX v7Version 7 UNIX
1Browse UNIX v10Version 10 UNIX

Manual Page Search

Manual Page Result

0 Command: tgmath | Section: 3 | Source: FreeBSD | File: tgmath.3.gz
TGMATH(3) FreeBSD Library Functions Manual TGMATH(3) NAME tgmath - type-generic macros SYNOPSIS #include <tgmath.h> DESCRIPTION The header <tgmath.h> provides type-generic macros for <math.h> and <complex.h> functions that have float (suffixed with f), double and long double (suffixed with l) versions. The arguments that vary across the three functions and have type float, double and long double, respectively, are called generic arguments. The following rules describe which function is actually called if a type- generic macro is invoked. If any generic argument has type long double or long double complex, the long double function is called. Else, if any generic argument has type double, double complex or an integer type, the double version is invoked. Otherwise, the macro expands to the float implementation. For the macros in the following table, both real and complex functions exist. The real functions are prototyped in <math.h> and the complex equivalents in <complex.h>. The complex function is called if any of the generic arguments is a complex value. Otherwise, the real equivalent is called. Macro real function complex function acos() acos() cacos() asin() asin() casin() atan() atan() catan() acosh() acosh() cacosh() asinh() asinh() casinh() atanh() atanh() catanh() cos() cos() ccos() sin() sin() csin() tan() tan() ctan() cosh() cosh() ccosh() sinh() sinh() csinh() tanh() tanh() ctanh() exp() exp() cexp() log() log() clog() pow() pow() cpow() sqrt() sqrt() csqrt() fabs() fabs() cabs() No complex functions exist for the following macros, so passing a complex value to a generic argument invokes undefined behaviour: atan2() fma() llround() remainder() cbrt() fmax() log10() remquo() ceil() fmin() log1p() rint() copysign() fmod() log2() round() erf() frexp() logb() scalbn() erfc() hypot() lrint() scalbln() exp2() ilogb() lround() tgamma() expm1() ldexp() nearbyint() trunc() fdim() lgamma() nextafter() floor() llrint() nexttoward() The following macros always expand to a complex function: carg() cimag() conj() cproj() creal() This header includes <complex.h> and <math.h>. STANDARDS The header <tgmath.h> conforms to ISO/IEC 9899:1999 ("ISO C99"). HISTORY The header <tgmath.h> first appeared in FreeBSD 5.3. COMPILER SUPPORT Before ISO/IEC 9899:2011 ("ISO C11"), the header <tgmath.h> could not be implemented with strictly conforming C code and needed special compiler support. As of ISO/IEC 9899:2011 ("ISO C11"), this header file can be implemented using the _Generic() language keyword. In addition to compilers that support this keyword, this header file works with GCC. BUGS Many of the functions mentioned here are not prototyped in <math.h> or <complex.h> as they are not yet implemented. This prevents the corresponding type-generic macro from working at all. FreeBSD 14.1-RELEASE-p8 January 4, 2012 FreeBSD 14.1-RELEASE-p8

Navigation Options