File: [cvs.NetBSD.org] / src / include / inttypes.h (download)
Revision 1.10.6.1, Wed Apr 22 07:18:58 2015 UTC (8 years, 11 months ago) by snj
Branch: netbsd-7
CVS Tags: netbsd-7-nhusb-base-20170116, netbsd-7-nhusb-base, netbsd-7-nhusb, netbsd-7-2-RELEASE, netbsd-7-1-RELEASE, netbsd-7-1-RC2, netbsd-7-1-RC1, netbsd-7-1-2-RELEASE, netbsd-7-1-1-RELEASE, netbsd-7-1, netbsd-7-0-RELEASE, netbsd-7-0-RC3, netbsd-7-0-RC2, netbsd-7-0-RC1, netbsd-7-0-2-RELEASE, netbsd-7-0-1-RELEASE, netbsd-7-0 Changes since 1.10: +16 -1
lines
Pull up following revision(s) (requested by roy in ticket #648):
common/lib/libc/stdlib/_strtoi.h: revisions 1.1, 1.2
common/lib/libc/stdlib/strtoi.c: revision 1.1
common/lib/libc/stdlib/strtou.c: revision 1.1
distrib/sets/lists/base/ad.aarch64: patch
distrib/sets/lists/base/ad.arm: patch
distrib/sets/lists/base/ad.mips: patch
distrib/sets/lists/base/ad.powerpc: patch
distrib/sets/lists/base/md.amd64: patch
distrib/sets/lists/base/md.sparc64: patch
distrib/sets/lists/base/shl.mi: patch
distrib/sets/lists/comp/mi: revision 1.1939
distrib/sets/lists/debug/ad.aarch64: patch
distrib/sets/lists/debug/ad.arm: patch
distrib/sets/lists/debug/ad.mips: patch
distrib/sets/lists/debug/ad.powerpc: patch
distrib/sets/lists/debug/md.amd64: patch
distrib/sets/lists/debug/md.sparc64: patch
distrib/sets/lists/debug/shl.mi: patch
include/inttypes.h: revision 1.11
lib/libc/shlib_version: patch
lib/libc/stdlib/Makefile.inc: revision 1.84
lib/libc/stdlib/strtol.3: revisions 1.27-1.31
lib/libc/stdlib/strtoul.3: revisions 1.26-1.29
sys/lib/libkern/Makefile.libkern: revision 1.37
sys/lib/libkern/libkern.h: revision 1.117
tools/compat/Makefile: revision 1.73
tools/compat/compat_defs.h: revision 1.101
tools/compat/configure.ac: revision 1.83
tools/compat/configure: revision 1.82
tools/compat/nbtool_config.h.in: revision 1.36
add strto{i,u} from Kamil Rytarowski as discussed in tech-userlevel.
--
strtoi and strtou additions
--
strtoi and strtou for the kernel
--
strtoi and strtou additions
--
strtoi and strtou man pages
--
strto{i,u}
--
regen
--
Remove trailing whitespace.
--
match variable names with man page (Kamil Rytarowski)
--
cleanups from (Kamil Rytarowski)
--
add strtoi strtou (Kamil Rytarowski)
--
PR/49640: Kamil Rytarowski: Improve error printing
--
Use existing month for Dd.
|
/* $NetBSD: inttypes.h,v 1.10.6.1 2015/04/22 07:18:58 snj Exp $ */
/*-
* Copyright (c) 2001 The NetBSD Foundation, Inc.
* All rights reserved.
*
* This code is derived from software contributed to The NetBSD Foundation
* by Klaus Klein.
*
* 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.
*
* THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. 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 FOUNDATION 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.
*/
#ifndef _INTTYPES_H_
#define _INTTYPES_H_
#include <sys/cdefs.h>
#include <sys/featuretest.h>
#include <sys/inttypes.h>
#include <machine/ansi.h>
#if defined(_BSD_WCHAR_T_) && !defined(__cplusplus)
typedef _BSD_WCHAR_T_ wchar_t;
#undef _BSD_WCHAR_T_
#endif
__BEGIN_DECLS
intmax_t strtoimax(const char * __restrict,
char ** __restrict, int);
uintmax_t strtoumax(const char * __restrict,
char ** __restrict, int);
intmax_t wcstoimax(const wchar_t * __restrict,
wchar_t ** __restrict, int);
uintmax_t wcstoumax(const wchar_t * __restrict,
wchar_t ** __restrict, int);
intmax_t imaxabs(intmax_t);
typedef struct {
intmax_t quot;
intmax_t rem;
} imaxdiv_t;
imaxdiv_t imaxdiv(intmax_t, intmax_t);
#if (_POSIX_C_SOURCE - 0) >= 200809L || defined(_NETBSD_SOURCE)
# ifndef __LOCALE_T_DECLARED
typedef struct _locale *locale_t;
# define __LOCALE_T_DECLARED
# endif
intmax_t strtoimax_l(const char * __restrict,
char ** __restrict, int, locale_t);
uintmax_t strtoumax_l(const char * __restrict,
char ** __restrict, int, locale_t);
intmax_t wcstoimax_l(const wchar_t * __restrict,
wchar_t ** __restrict, int, locale_t);
uintmax_t wcstoumax_l(const wchar_t * __restrict,
wchar_t ** __restrict, int, locale_t);
#endif
#if defined(_NETBSD_SOURCE)
intmax_t strtoi(const char * __restrict, char ** __restrict, int,
intmax_t, intmax_t, int *);
uintmax_t strtou(const char * __restrict, char ** __restrict, int,
uintmax_t, uintmax_t, int *);
/* i18n variations */
intmax_t strtoi_l(const char * __restrict, char ** __restrict, int,
intmax_t, intmax_t, int *, locale_t);
uintmax_t strtou_l(const char * __restrict, char ** __restrict, int,
uintmax_t, uintmax_t, int *, locale_t);
#endif /* defined(_NETBSD_SOURCE) */
__END_DECLS
#endif /* !_INTTYPES_H_ */