X-Git-Url: http://erislabs.net/gitweb/?a=blobdiff_plain;f=tests%2Ftest-floorl-ieee.c;h=24f9b775cf1496a9dfcbc96ceeb7644dc4da6853;hb=acb0726a65e9a6c954adcd50b50d4d02c016de26;hp=7ca6191a49c4d630e17e917661d46c83b4e807db;hpb=d60f3b0c6b0f93a601acd1cfd3923f94ca05abb0;p=gnulib.git diff --git a/tests/test-floorl-ieee.c b/tests/test-floorl-ieee.c index 7ca6191a4..24f9b775c 100644 --- a/tests/test-floorl-ieee.c +++ b/tests/test-floorl-ieee.c @@ -1,5 +1,5 @@ /* Test of rounding towards negative infinity. - Copyright (C) 2010-2011 Free Software Foundation, Inc. + Copyright (C) 2010-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 @@ -19,7 +19,10 @@ #include #include "fpucw.h" +#include "isnanl-nolibm.h" #include "minus-zero.h" +#include "infinity.h" +#include "nan.h" #include "macros.h" int @@ -44,5 +47,13 @@ main () ASSERT (!!signbit (floorl (-0.3L)) == !!signbit (minus_zerol)); ASSERT (!!signbit (floorl (-0.7L)) == !!signbit (minus_zerol)); + /* [MX] shaded specification in POSIX. */ + + /* NaN. */ + ASSERT (isnanl (floorl (NaNl ()))); + /* Infinity. */ + ASSERT (floorl (Infinityl ()) == Infinityl ()); + ASSERT (floorl (- Infinityl ()) == - Infinityl ()); + return 0; }