Module Name:    src
Committed By:   jruoho
Date:           Sat Apr 16 05:48:50 UTC 2011

Modified Files:
        src/lib/libm: Makefile
        src/lib/libm/man: ceil.3
Removed Files:
        src/lib/libm/man: floor.3

Log Message:
Merge floor(3) to ceil(3).


To generate a diff of this commit:
cvs rdiff -u -r1.106 -r1.107 src/lib/libm/Makefile
cvs rdiff -u -r1.17 -r1.18 src/lib/libm/man/ceil.3
cvs rdiff -u -r1.14 -r0 src/lib/libm/man/floor.3

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/lib/libm/Makefile
diff -u src/lib/libm/Makefile:1.106 src/lib/libm/Makefile:1.107
--- src/lib/libm/Makefile:1.106	Wed Apr 13 04:57:11 2011
+++ src/lib/libm/Makefile	Sat Apr 16 05:48:50 2011
@@ -1,4 +1,4 @@
-#  $NetBSD: Makefile,v 1.106 2011/04/13 04:57:11 jruoho Exp $
+#  $NetBSD: Makefile,v 1.107 2011/04/16 05:48:50 jruoho Exp $
 #
 #  @(#)Makefile 5.1beta 93/09/24
 #
@@ -203,7 +203,7 @@
 MAN+=	acos.3 acosh.3 asin.3 asinh.3 atan.3 atan2.3 atanh.3 \
 	ceil.3 copysign.3 cos.3 cosh.3 \
 	erf.3 exp.3 \
-	fabs.3 floor.3 fmod.3 frexp.3 hypot.3 ieee.3 \
+	fabs.3 fmod.3 frexp.3 hypot.3 ieee.3 \
 	ieee_test.3 isinff.3 j0.3 ldexp.3 lgamma.3 lrint.3 \
 	math.3 modf.3 nextafter.3 \
 	remainder.3 rint.3 round.3 \
@@ -230,7 +230,9 @@
 MLINKS+=atan.3 atanf.3
 MLINKS+=atan2.3 atan2f.3
 MLINKS+=atanh.3 atanhf.3
-MLINKS+=ceil.3 ceilf.3
+MLINKS+=ceil.3 ceilf.3 \
+	ceil.3 floor.3 \
+	ceil.3 floorf.3
 MLINKS+=copysign.3 copysignf.3 \
 	copysign.3 copysignl.3
 MLINKS+=cos.3 cosf.3
@@ -244,7 +246,6 @@
 	exp.3 pow.3 exp.3 powf.3 					\
 	exp.3 log2.3 exp.3 log2f.3
 MLINKS+=fabs.3 fabsf.3
-MLINKS+=floor.3 floorf.3
 MLINKS+=fmod.3 fmodf.3
 MLINKS+=hypot.3 hypotf.3
 MLINKS+=ieee.3 finite.3 ieee.3 finitef.3 				\

Index: src/lib/libm/man/ceil.3
diff -u src/lib/libm/man/ceil.3:1.17 src/lib/libm/man/ceil.3:1.18
--- src/lib/libm/man/ceil.3:1.17	Thu Aug  7 16:44:47 2003
+++ src/lib/libm/man/ceil.3	Sat Apr 16 05:48:50 2011
@@ -26,15 +26,17 @@
 .\" SUCH DAMAGE.
 .\"
 .\"     from: @(#)ceil.3	5.1 (Berkeley) 5/2/91
-.\"	$NetBSD: ceil.3,v 1.17 2003/08/07 16:44:47 agc Exp $
+.\"	$NetBSD: ceil.3,v 1.18 2011/04/16 05:48:50 jruoho Exp $
 .\"
-.Dd March 10, 1994
+.Dd April 16, 2011
 .Dt CEIL 3
 .Os
 .Sh NAME
 .Nm ceil ,
-.Nm ceilf
-.Nd "round to smallest integral value greater than or equal to x"
+.Nm ceilf ,
+.Nm floor ,
+.Nm floorf
+.Nd ceiling and floor
 .Sh LIBRARY
 .Lb libm
 .Sh SYNOPSIS
@@ -43,6 +45,10 @@
 .Fn ceil "double x"
 .Ft float
 .Fn ceilf "float x"
+.Ft double
+.Fn floor "double x"
+.Ft float
+.Fn floorf "float x"
 .Sh DESCRIPTION
 The
 .Fn ceil
@@ -51,15 +57,23 @@
 functions return the smallest integral value
 greater than or equal to
 .Fa x .
+Conversely, the
+.Fn floor
+and
+.Fn floorf
+functions return the largest integral value
+less than or equal to
+.Fa x .
 .Sh SEE ALSO
 .Xr abs 3 ,
 .Xr fabs 3 ,
-.Xr floor 3 ,
-.Xr ieee 3 ,
 .Xr math 3 ,
+.Xr nextafter 3 ,
 .Xr rint 3
 .Sh STANDARDS
+The described functions conform to
+.St -isoC-99 .
+.Sh BUGS
 The
-.Fn ceil
-function conforms to
-.St -ansiC .
+.Vt long double
+variants of the functions are not yet supported.

Reply via email to