OSDN Git Service

(split) LDP: Update original to LDP v3.38.
[linuxjm/LDP_man-pages.git] / original / man3 / strtoimax.3
1 .\" Copyright (c) 2003 Andries Brouwer (aeb@cwi.nl)
2 .\"
3 .\" This is free documentation; you can redistribute it and/or
4 .\" modify it under the terms of the GNU General Public License as
5 .\" published by the Free Software Foundation; either version 2 of
6 .\" the License, or (at your option) any later version.
7 .\"
8 .\" The GNU General Public License's references to "object code"
9 .\" and "executables" are to be interpreted as the output of any
10 .\" document formatting or typesetting system, including
11 .\" intermediate and printed output.
12 .\"
13 .\" This manual is distributed in the hope that it will be useful,
14 .\" but WITHOUT ANY WARRANTY; without even the implied warranty of
15 .\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16 .\" GNU General Public License for more details.
17 .\"
18 .\" You should have received a copy of the GNU General Public
19 .\" License along with this manual; if not, write to the Free
20 .\" Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111,
21 .\" USA.
22 .\"
23 .TH STRTOIMAX 3 2003-11-28 "" "Linux Programmer's Manual"
24 .SH NAME
25 strtoimax, strtoumax \- convert string to integer
26 .SH SYNOPSIS
27 .nf
28 .B #include <inttypes.h>
29 .sp
30 .BI "intmax_t strtoimax(const char *" nptr ", char **" endptr ", int " base );
31 .br
32 .BI "uintmax_t strtoumax(const char *" nptr ", char **" endptr ", int " base );
33 .fi
34 .SH DESCRIPTION
35 These functions are just like
36 .BR strtol (3)
37 and
38 .BR strtoul (3),
39 except that they return a value of type
40 .I intmax_t
41 and
42 .IR uintmax_t ,
43 respectively.
44 .SH "RETURN VALUE"
45 On success, the converted value is returned.
46 If nothing was found to convert, zero is returned.
47 On overflow or underflow
48 .B INTMAX_MAX
49 or
50 .B INTMAX_MIN
51 or
52 .B UINTMAX_MAX
53 is returned, and
54 .I errno
55 is set to
56 .BR ERANGE .
57 .SH "CONFORMING TO"
58 C99, POSIX.1-2001.
59 .SH "SEE ALSO"
60 .BR imaxabs (3),
61 .BR imaxdiv (3),
62 .BR strtol (3),
63 .BR strtoul (3),
64 .BR wcstoimax (3)