X-Git-Url: http://erislabs.net/gitweb/?a=blobdiff_plain;f=lib%2Ftruncl.c;h=bdeb01e133ed409ee67b5ebb88d65951bdf20945;hb=3d25ec76d62050ec9a2f0cf861b66122132f1539;hp=b391ecb4eae0bcdc1f6c3c0acdbcb6a03b07c740;hpb=3030c5b5e0a5199e16b05927da72c43c42f211c3;p=gnulib.git diff --git a/lib/truncl.c b/lib/truncl.c index b391ecb4e..bdeb01e13 100644 --- a/lib/truncl.c +++ b/lib/truncl.c @@ -1,5 +1,5 @@ /* Round towards zero. - Copyright (C) 2007, 2009 Free Software Foundation, Inc. + Copyright (C) 2007, 2009-2012 Free Software Foundation, Inc. This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -16,5 +16,22 @@ /* Written by Bruno Haible , 2007. */ -#define USE_LONG_DOUBLE -#include "trunc.c" +#include + +#if HAVE_SAME_LONG_DOUBLE_AS_DOUBLE + +/* Specification. */ +# include + +long double +truncl (long double x) +{ + return trunc (x); +} + +#else + +# define USE_LONG_DOUBLE +# include "trunc.c" + +#endif