X-Git-Url: https://pd.if.org/git/?a=blobdiff_plain;f=functions%2Fmath%2Fnearbyint.c;h=3937dbebb37d6890606e0f5129a08bd0f106290c;hb=c8f799d852e3698468a78954d82588e841cc0b70;hp=675951d73936a3dc33ca375ddf27dd1f8d5af759;hpb=dcc8a8e99f69e090a03b7b868443addbc0817820;p=pdclib.old diff --git a/functions/math/nearbyint.c b/functions/math/nearbyint.c index 675951d..3937dbe 100644 --- a/functions/math/nearbyint.c +++ b/functions/math/nearbyint.c @@ -1,19 +1,17 @@ -// ---------------------------------------------------------------------------- -// $Id$ -// ---------------------------------------------------------------------------- -// Public Domain C Library - http://pdclib.sourceforge.net -// This code is Public Domain. Use, modify, and redistribute at will. -// ---------------------------------------------------------------------------- +/* ---------------------------------------------------------------------------- + * $Id$ + * ---------------------------------------------------------------------------- + * Public Domain C Library - http://pdclib.sourceforge.net + * This code is Public Domain. Use, modify, and redistribute at will. + * --------------------------------------------------------------------------*/ -// ---------------------------------------------------------------------------- -// C++ - -float nearbyint( float x ) { /* TODO */ }; -long double nearbyint( long double x ) { /* TODO */ }; +double nearbyint( double x ) { /* TODO */ }; -// ---------------------------------------------------------------------------- -// Standard C +/* Therx code +{ + return round( x ); +} +*/ -double nearbyint( double x ) { /* TODO */ }; float nearbyintf( float x ) { /* TODO */ }; long double nearbyintl( long double x ) { /* TODO */ };