Collect abs(3), labs(3), llabs(3), and imaxabs(3) to a single small page.
This commit is contained in:
parent
2ba8acef07
commit
19606f522d
@ -1,4 +1,4 @@
|
||||
# $NetBSD: Makefile.inc,v 1.75 2010/11/14 18:11:43 tron Exp $
|
||||
# $NetBSD: Makefile.inc,v 1.76 2011/04/13 06:56:50 jruoho Exp $
|
||||
# from: @(#)Makefile.inc 8.3 (Berkeley) 2/4/95
|
||||
|
||||
# stdlib sources
|
||||
@ -43,9 +43,9 @@ MAN+= a64l.3 abort.3 abs.3 alloca.3 atexit.3 atof.3 atoi.3 atol.3 atoll.3 \
|
||||
exit.3 \
|
||||
getenv.3 getopt.3 getopt_long.3 getsubopt.3 grantpt.3 \
|
||||
hcreate.3 \
|
||||
imaxabs.3 imaxdiv.3 insque.3 \
|
||||
imaxdiv.3 insque.3 \
|
||||
jemalloc.3 \
|
||||
labs.3 ldiv.3 llabs.3 lldiv.3 lsearch.3 \
|
||||
ldiv.3 lldiv.3 lsearch.3 \
|
||||
malloc.3 memory.3 mi_vector_hash.3 \
|
||||
posix_memalign.3 posix_openpt.3 ptsname.3 \
|
||||
qabs.3 qdiv.3 qsort.3 \
|
||||
@ -56,6 +56,9 @@ MAN+= a64l.3 abort.3 abs.3 alloca.3 atexit.3 atof.3 atoi.3 atol.3 atoll.3 \
|
||||
|
||||
MLINKS+=a64l.3 l64a.3
|
||||
MLINKS+=a64l.3 l64a_r.3
|
||||
MLINKS+=abs.3 labs.3 \
|
||||
abs.3 llabs.3 \
|
||||
abs.3 imaxabs.3
|
||||
MLINKS+=getenv.3 setenv.3 getenv.3 unsetenv.3 getenv.3 putenv.3
|
||||
MLINKS+=getenv.3 getenv_r.3
|
||||
MLINKS+=hcreate.3 hdestroy.3 hcreate.3 hsearch.3
|
||||
|
@ -1,4 +1,4 @@
|
||||
.\" $NetBSD: abs.3,v 1.13 2008/08/04 21:29:27 matt Exp $
|
||||
.\" $NetBSD: abs.3,v 1.14 2011/04/13 06:56:50 jruoho Exp $
|
||||
.\"
|
||||
.\" Copyright (c) 1990, 1991, 1993
|
||||
.\" The Regents of the University of California. All rights reserved.
|
||||
@ -33,44 +33,41 @@
|
||||
.\"
|
||||
.\" from: @(#)abs.3 8.1 (Berkeley) 6/4/93
|
||||
.\"
|
||||
.Dd June 4, 1993
|
||||
.Dd April 13, 2011
|
||||
.Dt ABS 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
.Nm abs
|
||||
.Nd integer absolute value function
|
||||
.Nm abs ,
|
||||
.Nm labs ,
|
||||
.Nm llabs ,
|
||||
.Nm imaxabs
|
||||
.Nd functions for integer absolute value
|
||||
.Sh LIBRARY
|
||||
.Lb libc
|
||||
.Sh SYNOPSIS
|
||||
.In stdlib.h
|
||||
.Ft int
|
||||
.Fn abs "int j"
|
||||
.Fn abs "int x"
|
||||
.Ft long int
|
||||
.Fn labs "long int x"
|
||||
.Ft long long int
|
||||
.Fn llabs "long long int x"
|
||||
.In inttypes.h
|
||||
.Ft intmax_t
|
||||
.Fn imaxabs "intmax_t x"
|
||||
.Sh DESCRIPTION
|
||||
The
|
||||
.Fn abs
|
||||
function
|
||||
computes
|
||||
the absolute value of the integer
|
||||
.Ar j .
|
||||
.Sh RETURN VALUES
|
||||
The
|
||||
.Fn abs
|
||||
function
|
||||
returns
|
||||
the absolute value.
|
||||
These functions return the absolute value of the integer
|
||||
.Fa x .
|
||||
The listed functions differ only with respect
|
||||
to the type of the return value and
|
||||
.Fa x .
|
||||
.Sh SEE ALSO
|
||||
.Xr cabs 3 ,
|
||||
.Xr fabs 3 ,
|
||||
.Xr floor 3 ,
|
||||
.Xr hypot 3 ,
|
||||
.Xr imaxabs 3 ,
|
||||
.Xr labs 3 ,
|
||||
.Xr llabs 3 ,
|
||||
.Xr math 3
|
||||
.Sh STANDARDS
|
||||
The
|
||||
.Fn abs
|
||||
function conforms to
|
||||
.St -ansiC .
|
||||
The described functions conform to
|
||||
.St -isoC-99 .
|
||||
.Sh BUGS
|
||||
The absolute value of the most negative integer remains negative.
|
||||
|
@ -1,70 +0,0 @@
|
||||
.\" $NetBSD: imaxabs.3,v 1.4 2011/04/13 06:41:11 jruoho Exp $
|
||||
.\"
|
||||
.\" Copyright (c) 1990, 1991, 1993
|
||||
.\" The Regents of the University of California. All rights reserved.
|
||||
.\"
|
||||
.\" This code is derived from software contributed to Berkeley by
|
||||
.\" the American National Standards Committee X3, on Information
|
||||
.\" Processing Systems.
|
||||
.\"
|
||||
.\" Redistribution and use in source and binary forms, with or without
|
||||
.\" modification, are permitted provided that the following conditions
|
||||
.\" are met:
|
||||
.\" 1. Redistributions of source code must retain the above copyright
|
||||
.\" notice, this list of conditions and the following disclaimer.
|
||||
.\" 2. Redistributions in binary form must reproduce the above copyright
|
||||
.\" notice, this list of conditions and the following disclaimer in the
|
||||
.\" documentation and/or other materials provided with the distribution.
|
||||
.\" 3. Neither the name of the University nor the names of its contributors
|
||||
.\" may be used to endorse or promote products derived from this software
|
||||
.\" without specific prior written permission.
|
||||
.\"
|
||||
.\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
||||
.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
||||
.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
||||
.\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
||||
.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
||||
.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
||||
.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
||||
.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
||||
.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
||||
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||||
.\" SUCH DAMAGE.
|
||||
.\"
|
||||
.\" from: @(#)labs.3 8.1 (Berkeley) 6/4/93
|
||||
.\"
|
||||
.Dd April 13, 2011
|
||||
.Dt IMAXABS 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
.Nm imaxabs
|
||||
.Nd return the absolute value of a intmax_t
|
||||
.Sh LIBRARY
|
||||
.Lb libc
|
||||
.Sh SYNOPSIS
|
||||
.In inttypes.h
|
||||
.Ft intmax_t
|
||||
.Fn imaxabs "intmax_t x"
|
||||
.Sh DESCRIPTION
|
||||
The
|
||||
.Fn imaxabs
|
||||
function
|
||||
returns the absolute value of the
|
||||
.Vt intmax_t
|
||||
integer
|
||||
.Ar x .
|
||||
.Sh SEE ALSO
|
||||
.Xr abs 3 ,
|
||||
.Xr cabs 3 ,
|
||||
.Xr floor 3 ,
|
||||
.Xr labs 3 ,
|
||||
.Xr llabs 3 ,
|
||||
.Xr math 3
|
||||
.Sh STANDARDS
|
||||
The
|
||||
.Fn imaxabs
|
||||
function
|
||||
conforms to
|
||||
.St -isoC-99 .
|
||||
.Sh BUGS
|
||||
The absolute value of the most negative integer remains negative.
|
@ -1,68 +0,0 @@
|
||||
.\" $NetBSD: labs.3,v 1.11 2008/08/04 21:29:27 matt Exp $
|
||||
.\"
|
||||
.\" Copyright (c) 1990, 1991, 1993
|
||||
.\" The Regents of the University of California. All rights reserved.
|
||||
.\"
|
||||
.\" This code is derived from software contributed to Berkeley by
|
||||
.\" the American National Standards Committee X3, on Information
|
||||
.\" Processing Systems.
|
||||
.\"
|
||||
.\" Redistribution and use in source and binary forms, with or without
|
||||
.\" modification, are permitted provided that the following conditions
|
||||
.\" are met:
|
||||
.\" 1. Redistributions of source code must retain the above copyright
|
||||
.\" notice, this list of conditions and the following disclaimer.
|
||||
.\" 2. Redistributions in binary form must reproduce the above copyright
|
||||
.\" notice, this list of conditions and the following disclaimer in the
|
||||
.\" documentation and/or other materials provided with the distribution.
|
||||
.\" 3. Neither the name of the University nor the names of its contributors
|
||||
.\" may be used to endorse or promote products derived from this software
|
||||
.\" without specific prior written permission.
|
||||
.\"
|
||||
.\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
||||
.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
||||
.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
||||
.\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
||||
.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
||||
.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
||||
.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
||||
.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
||||
.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
||||
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||||
.\" SUCH DAMAGE.
|
||||
.\"
|
||||
.\" from: @(#)labs.3 8.1 (Berkeley) 6/4/93
|
||||
.\"
|
||||
.Dd June 4, 1993
|
||||
.Dt LABS 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
.Nm labs
|
||||
.Nd return the absolute value of a long integer
|
||||
.Sh LIBRARY
|
||||
.Lb libc
|
||||
.Sh SYNOPSIS
|
||||
.In stdlib.h
|
||||
.Ft long int
|
||||
.Fn labs "long int j"
|
||||
.Sh DESCRIPTION
|
||||
The
|
||||
.Fn labs
|
||||
function
|
||||
returns the absolute value of the long integer
|
||||
.Ar j .
|
||||
.Sh SEE ALSO
|
||||
.Xr abs 3 ,
|
||||
.Xr cabs 3 ,
|
||||
.Xr floor 3 ,
|
||||
.Xr imaxabs 3 ,
|
||||
.Xr llabs 3 ,
|
||||
.Xr math 3
|
||||
.Sh STANDARDS
|
||||
The
|
||||
.Fn labs
|
||||
function
|
||||
conforms to
|
||||
.St -ansiC .
|
||||
.Sh BUGS
|
||||
The absolute value of the most negative integer remains negative.
|
@ -1,68 +0,0 @@
|
||||
.\" $NetBSD: llabs.3,v 1.7 2008/08/04 21:29:27 matt Exp $
|
||||
.\"
|
||||
.\" Copyright (c) 1990, 1991, 1993
|
||||
.\" The Regents of the University of California. All rights reserved.
|
||||
.\"
|
||||
.\" This code is derived from software contributed to Berkeley by
|
||||
.\" the American National Standards Committee X3, on Information
|
||||
.\" Processing Systems.
|
||||
.\"
|
||||
.\" Redistribution and use in source and binary forms, with or without
|
||||
.\" modification, are permitted provided that the following conditions
|
||||
.\" are met:
|
||||
.\" 1. Redistributions of source code must retain the above copyright
|
||||
.\" notice, this list of conditions and the following disclaimer.
|
||||
.\" 2. Redistributions in binary form must reproduce the above copyright
|
||||
.\" notice, this list of conditions and the following disclaimer in the
|
||||
.\" documentation and/or other materials provided with the distribution.
|
||||
.\" 3. Neither the name of the University nor the names of its contributors
|
||||
.\" may be used to endorse or promote products derived from this software
|
||||
.\" without specific prior written permission.
|
||||
.\"
|
||||
.\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
||||
.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
||||
.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
||||
.\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
||||
.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
||||
.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
||||
.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
||||
.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
||||
.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
||||
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||||
.\" SUCH DAMAGE.
|
||||
.\"
|
||||
.\" from: @(#)labs.3 8.1 (Berkeley) 6/4/93
|
||||
.\"
|
||||
.Dd March 6, 2000
|
||||
.Dt LLABS 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
.Nm llabs
|
||||
.Nd return the absolute value of a long long integer
|
||||
.Sh LIBRARY
|
||||
.Lb libc
|
||||
.Sh SYNOPSIS
|
||||
.In stdlib.h
|
||||
.Ft long long int
|
||||
.Fn llabs "long long int j"
|
||||
.Sh DESCRIPTION
|
||||
The
|
||||
.Fn llabs
|
||||
function
|
||||
returns the absolute value of the long long integer
|
||||
.Ar j .
|
||||
.Sh SEE ALSO
|
||||
.Xr abs 3 ,
|
||||
.Xr cabs 3 ,
|
||||
.Xr floor 3 ,
|
||||
.Xr imaxabs 3 ,
|
||||
.Xr labs 3 ,
|
||||
.Xr math 3
|
||||
.Sh STANDARDS
|
||||
The
|
||||
.Fn llabs
|
||||
function
|
||||
conforms to
|
||||
.St -isoC-99 .
|
||||
.Sh BUGS
|
||||
The absolute value of the most negative integer remains negative.
|
Loading…
Reference in New Issue
Block a user