about summary refs log tree commit diff
path: root/math/test-tgmath.c
diff options
context:
space:
mode:
authorJoseph Myers <joseph@codesourcery.com>2017-06-28 16:19:47 +0000
committerJoseph Myers <joseph@codesourcery.com>2017-06-28 16:19:47 +0000
commitcfa44345234e161cb59987ed70e04719ba155867 (patch)
treec7d4036635f771b556821b48edd2d800cf1cdb8b /math/test-tgmath.c
parent51737193a9810ceb1c516a2a71444fa70bcf8500 (diff)
downloadglibc-cfa44345234e161cb59987ed70e04719ba155867.tar.gz
glibc-cfa44345234e161cb59987ed70e04719ba155867.tar.xz
glibc-cfa44345234e161cb59987ed70e04719ba155867.zip
Simplify tgmath.h for integer return types.
The tgmath.h macros for function with integer return types generate
unnecessary casts to the return type.  Since in those cases the return
type does not depend on the argument type, all the cases in the
conditional expressions already have the right type, and no casts are
needed; this patch removes them.

Tested for x86_64.

	* math/tgmath.h (__TGMATH_UNARY_REAL_RET_ONLY): Do not take or
	cast to return type argument.
	(__TGMATH_TERNARY_FIRST_REAL_RET_ONLY): Likewise.
	(lrint): Update call to __TGMATH_UNARY_REAL_RET_ONLY.
	(llrint): Likewise.
	(lround): Likewise.
	(llround): Likewise.
	(ilogb): Likewise.
	(llogb): Likewise.
	(fromfp): Update call to __TGMATH_TERNARY_FIRST_REAL_RET_ONLY.
	(ufromfp): Likewise.
	(fromfpx): Likewise.
	(ufromfpx): Likewise.
Diffstat (limited to 'math/test-tgmath.c')
0 files changed, 0 insertions, 0 deletions