xref: /illumos-gate/usr/src/lib/libc/inc/libc.h (revision dd699a3e)
17c478bd9Sstevel@tonic-gate /*
27c478bd9Sstevel@tonic-gate  * CDDL HEADER START
37c478bd9Sstevel@tonic-gate  *
47c478bd9Sstevel@tonic-gate  * The contents of this file are subject to the terms of the
5494a4c51Sraf  * Common Development and Distribution License (the "License").
6494a4c51Sraf  * You may not use this file except in compliance with the License.
77c478bd9Sstevel@tonic-gate  *
87c478bd9Sstevel@tonic-gate  * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
97c478bd9Sstevel@tonic-gate  * or http://www.opensolaris.org/os/licensing.
107c478bd9Sstevel@tonic-gate  * See the License for the specific language governing permissions
117c478bd9Sstevel@tonic-gate  * and limitations under the License.
127c478bd9Sstevel@tonic-gate  *
137c478bd9Sstevel@tonic-gate  * When distributing Covered Code, include this CDDL HEADER in each
147c478bd9Sstevel@tonic-gate  * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
157c478bd9Sstevel@tonic-gate  * If applicable, add the following below this CDDL HEADER, with the
167c478bd9Sstevel@tonic-gate  * fields enclosed by brackets "[]" replaced with your own identifying
177c478bd9Sstevel@tonic-gate  * information: Portions Copyright [yyyy] [name of copyright owner]
187c478bd9Sstevel@tonic-gate  *
197c478bd9Sstevel@tonic-gate  * CDDL HEADER END
207c478bd9Sstevel@tonic-gate  */
210ec57554Sraf 
227c478bd9Sstevel@tonic-gate /*
238fd04b83SRoger A. Faulkner  * Copyright 2010 Sun Microsystems, Inc.  All rights reserved.
247c478bd9Sstevel@tonic-gate  * Use is subject to license terms.
257c478bd9Sstevel@tonic-gate  */
267c478bd9Sstevel@tonic-gate 
277c478bd9Sstevel@tonic-gate /*
287c478bd9Sstevel@tonic-gate  * This is where all the interfaces that are internal to libc
297c478bd9Sstevel@tonic-gate  * which do not have a better home live
307c478bd9Sstevel@tonic-gate  */
317c478bd9Sstevel@tonic-gate 
327c478bd9Sstevel@tonic-gate #ifndef _LIBC_H
337c478bd9Sstevel@tonic-gate #define	_LIBC_H
347c478bd9Sstevel@tonic-gate 
357c478bd9Sstevel@tonic-gate #include <thread.h>
367c478bd9Sstevel@tonic-gate #include <stdio.h>
37494a4c51Sraf #include <dirent.h>
387c478bd9Sstevel@tonic-gate #include <ucontext.h>
397c478bd9Sstevel@tonic-gate #include <nsswitch.h>
407c478bd9Sstevel@tonic-gate #include <stddef.h>
417c478bd9Sstevel@tonic-gate #include <poll.h>
427c478bd9Sstevel@tonic-gate #include <sys/dl.h>
437c478bd9Sstevel@tonic-gate #include <sys/door.h>
447c478bd9Sstevel@tonic-gate #include <sys/ieeefp.h>
457c478bd9Sstevel@tonic-gate #include <sys/mount.h>
467c478bd9Sstevel@tonic-gate #include <floatingpoint.h>
477c478bd9Sstevel@tonic-gate #include <nl_types.h>
487c478bd9Sstevel@tonic-gate #include <regex.h>
497c478bd9Sstevel@tonic-gate #include <stdarg.h>
507c478bd9Sstevel@tonic-gate #include <wchar.h>
517c478bd9Sstevel@tonic-gate #include <wctype.h>
52d8ac9b2dSmarks #include <libnvpair.h>
53dd2ed563SToomas Soome #include <setjmp.h>
547c478bd9Sstevel@tonic-gate 
557c478bd9Sstevel@tonic-gate #ifdef	__cplusplus
567c478bd9Sstevel@tonic-gate extern "C" {
577c478bd9Sstevel@tonic-gate #endif
587c478bd9Sstevel@tonic-gate 
597c478bd9Sstevel@tonic-gate extern void __set_panicstr(const char *);
607c478bd9Sstevel@tonic-gate extern void _rewind_unlocked(FILE *);
617c478bd9Sstevel@tonic-gate extern long _sysconfig(int);
627c478bd9Sstevel@tonic-gate extern int kill(pid_t pid, int sig);
637c478bd9Sstevel@tonic-gate 
647c478bd9Sstevel@tonic-gate extern int primary_link_map;
65dd2ed563SToomas Soome extern void _thr_exit(void *) __NORETURN;
667c478bd9Sstevel@tonic-gate extern int thr_main(void);
677c478bd9Sstevel@tonic-gate extern int thr_kill(thread_t tid, int sig);
687c478bd9Sstevel@tonic-gate extern thread_t thr_self(void);
697c478bd9Sstevel@tonic-gate extern int mutex_lock(mutex_t *mp);
707c478bd9Sstevel@tonic-gate extern int mutex_unlock(mutex_t *mp);
7198c1a6b4Sraf extern void callout_lock_enter(void);
7298c1a6b4Sraf extern void callout_lock_exit(void);
737c478bd9Sstevel@tonic-gate extern void *lmalloc(size_t);
747c478bd9Sstevel@tonic-gate extern void lfree(void *, size_t);
75d8ac9b2dSmarks extern void libc_nvlist_free(nvlist_t *);
76d8ac9b2dSmarks extern int libc_nvlist_lookup_uint64(nvlist_t *, const char *, uint64_t *);
777c478bd9Sstevel@tonic-gate extern void *libc_malloc(size_t);
787c478bd9Sstevel@tonic-gate extern void *libc_realloc(void *, size_t);
797c478bd9Sstevel@tonic-gate extern void libc_free(void *);
807c478bd9Sstevel@tonic-gate extern char *libc_strdup(const char *);
817c478bd9Sstevel@tonic-gate extern int _pollsys(struct pollfd *, nfds_t, const timespec_t *,
827c478bd9Sstevel@tonic-gate 	const sigset_t *);
837c478bd9Sstevel@tonic-gate 
84494a4c51Sraf /*
85494a4c51Sraf  * The private_DIR structure is the same as the DIR structure,
86494a4c51Sraf  * with the addition of a mutex lock for libc's internal use.
87494a4c51Sraf  */
88494a4c51Sraf typedef struct {
89494a4c51Sraf 	DIR	dd_dir;
90494a4c51Sraf 	mutex_t	dd_lock;
91494a4c51Sraf } private_DIR;
92494a4c51Sraf 
937c478bd9Sstevel@tonic-gate #if !defined(_LP64)
947c478bd9Sstevel@tonic-gate /*
957c478bd9Sstevel@tonic-gate  * getdents64 transitional interface is intentionally internal to libc
967c478bd9Sstevel@tonic-gate  */
977c478bd9Sstevel@tonic-gate extern int getdents64(int, struct dirent64 *, size_t);
987c478bd9Sstevel@tonic-gate #endif
997c478bd9Sstevel@tonic-gate 
1007c478bd9Sstevel@tonic-gate extern int _scrwidth(wchar_t);
1017c478bd9Sstevel@tonic-gate 
1027c478bd9Sstevel@tonic-gate extern int64_t __div64(int64_t, int64_t);
1037c478bd9Sstevel@tonic-gate extern int64_t __rem64(int64_t, int64_t);
1047c478bd9Sstevel@tonic-gate extern uint64_t __udiv64(uint64_t, uint64_t);
1057c478bd9Sstevel@tonic-gate extern uint64_t __urem64(uint64_t, uint64_t);
1067c478bd9Sstevel@tonic-gate extern int64_t __mul64(int64_t, int64_t);
1077c478bd9Sstevel@tonic-gate extern uint64_t __umul64(uint64_t, uint64_t);
1087c478bd9Sstevel@tonic-gate 
1097c478bd9Sstevel@tonic-gate 
1107c478bd9Sstevel@tonic-gate /*
1117c478bd9Sstevel@tonic-gate  * Rounding direction functions
1127c478bd9Sstevel@tonic-gate  */
1137c478bd9Sstevel@tonic-gate #if defined(__i386) || defined(__amd64)
1147c478bd9Sstevel@tonic-gate extern enum fp_direction_type __xgetRD(void);
1157c478bd9Sstevel@tonic-gate #elif defined(__sparc)
1167c478bd9Sstevel@tonic-gate extern enum fp_direction_type _QgetRD(void);
1177c478bd9Sstevel@tonic-gate #else
1187c478bd9Sstevel@tonic-gate #error Unknown architecture!
1197c478bd9Sstevel@tonic-gate #endif
1207c478bd9Sstevel@tonic-gate 
1218fd04b83SRoger A. Faulkner /*
1228fd04b83SRoger A. Faulkner  * defined in open.c
1238fd04b83SRoger A. Faulkner  */
1248fd04b83SRoger A. Faulkner extern	int	__open(const char *, int, mode_t);
1258fd04b83SRoger A. Faulkner extern	int	__open64(const char *, int, mode_t);
1268fd04b83SRoger A. Faulkner extern	int	__openat(int, const char *, int, mode_t);
1278fd04b83SRoger A. Faulkner extern	int	__openat64(int, const char *, int, mode_t);
1287c478bd9Sstevel@tonic-gate 
1297c478bd9Sstevel@tonic-gate /*
1307c478bd9Sstevel@tonic-gate  * defined in hex_bin.c
1317c478bd9Sstevel@tonic-gate  */
1327c478bd9Sstevel@tonic-gate extern void __hex_to_single(decimal_record *, enum fp_direction_type,
1337c478bd9Sstevel@tonic-gate 	single *, fp_exception_field_type *);
1347c478bd9Sstevel@tonic-gate extern void __hex_to_double(decimal_record *, enum fp_direction_type,
1357c478bd9Sstevel@tonic-gate 	double *, fp_exception_field_type *);
1367c478bd9Sstevel@tonic-gate #if defined(__sparc)
1377c478bd9Sstevel@tonic-gate extern void __hex_to_quadruple(decimal_record *, enum fp_direction_type,
1387c478bd9Sstevel@tonic-gate 	quadruple *, fp_exception_field_type *);
1397c478bd9Sstevel@tonic-gate #elif defined(__i386) || defined(__amd64)
1407c478bd9Sstevel@tonic-gate extern void __hex_to_extended(decimal_record *, enum fp_direction_type,
1417c478bd9Sstevel@tonic-gate 	extended *, fp_exception_field_type *);
1427c478bd9Sstevel@tonic-gate #else
1437c478bd9Sstevel@tonic-gate #error Unknown architecture
1447c478bd9Sstevel@tonic-gate #endif
1457c478bd9Sstevel@tonic-gate 
1467c478bd9Sstevel@tonic-gate /*
1477c478bd9Sstevel@tonic-gate  * defined in ctime.c
1487c478bd9Sstevel@tonic-gate  */
1497c478bd9Sstevel@tonic-gate extern char	*__posix_asctime_r(const struct tm *, char *);
1507c478bd9Sstevel@tonic-gate 
1517c478bd9Sstevel@tonic-gate /*
1527c478bd9Sstevel@tonic-gate  * Internal routine from fsync.c
1537c478bd9Sstevel@tonic-gate  */
1547c478bd9Sstevel@tonic-gate extern int __fdsync(int, int);	/* 2nd arg may be wrong in 64bit mode */
1557c478bd9Sstevel@tonic-gate 
1567c478bd9Sstevel@tonic-gate /*
1577c478bd9Sstevel@tonic-gate  * Internal routine from _xregs_clrptr.c
1587c478bd9Sstevel@tonic-gate  */
1597c478bd9Sstevel@tonic-gate extern void _xregs_clrptr(ucontext_t *);
1607c478bd9Sstevel@tonic-gate 
1617c478bd9Sstevel@tonic-gate /*
1627c478bd9Sstevel@tonic-gate  * Internal routine from nfssys.c
1637c478bd9Sstevel@tonic-gate  */
1647c478bd9Sstevel@tonic-gate extern int _nfssys(int, void *); /* int in 64bit mode ???, void * ??? */
1657c478bd9Sstevel@tonic-gate 
1667c478bd9Sstevel@tonic-gate /*
1677c478bd9Sstevel@tonic-gate  * Internal routine from psetsys.c
1687c478bd9Sstevel@tonic-gate  */
1697c478bd9Sstevel@tonic-gate extern int _pset(int, ...); /* int in 64bit mode ??? */
1707c478bd9Sstevel@tonic-gate 
1717c478bd9Sstevel@tonic-gate /*
1727c478bd9Sstevel@tonic-gate  * defined in sigpending.s
1737c478bd9Sstevel@tonic-gate  */
1747c478bd9Sstevel@tonic-gate extern int __sigfillset(sigset_t *);
1757c478bd9Sstevel@tonic-gate 
1767c478bd9Sstevel@tonic-gate /*
1777c478bd9Sstevel@tonic-gate  * defined in sparc/fp/_Q_set_except.c and i386/fp/exception.c
1787c478bd9Sstevel@tonic-gate  */
1797c478bd9Sstevel@tonic-gate extern int _Q_set_exception(unsigned int);
1807c478bd9Sstevel@tonic-gate 
1817c478bd9Sstevel@tonic-gate /*
1827c478bd9Sstevel@tonic-gate  * defined in nsparse.c
1837c478bd9Sstevel@tonic-gate  */
1847c478bd9Sstevel@tonic-gate extern struct __nsw_switchconfig *_nsw_getoneconfig(const char *name,
1857c478bd9Sstevel@tonic-gate 	char *linep, enum __nsw_parse_err *);
1867c478bd9Sstevel@tonic-gate extern struct __nsw_switchconfig_v1 *_nsw_getoneconfig_v1(const char *name,
1877c478bd9Sstevel@tonic-gate 	char *linep, enum __nsw_parse_err *);
1887c478bd9Sstevel@tonic-gate 
1897c478bd9Sstevel@tonic-gate /*
1907c478bd9Sstevel@tonic-gate  * Internal routine from getusershell.c
1917c478bd9Sstevel@tonic-gate  */
1927c478bd9Sstevel@tonic-gate extern char *getusershell(void);
1937c478bd9Sstevel@tonic-gate 
1947c478bd9Sstevel@tonic-gate /*
1957c478bd9Sstevel@tonic-gate  * defined in _sigaction.s
1967c478bd9Sstevel@tonic-gate  */
1977c478bd9Sstevel@tonic-gate extern int __sigaction(int, const struct sigaction *, struct sigaction *);
1987c478bd9Sstevel@tonic-gate 
199dd2ed563SToomas Soome /*
200dd2ed563SToomas Soome  * defined in siglongjmp.c
201dd2ed563SToomas Soome  */
202dd2ed563SToomas Soome extern void _siglongjmp(sigjmp_buf, int) __NORETURN;
203dd2ed563SToomas Soome 
2047c478bd9Sstevel@tonic-gate /*
2057c478bd9Sstevel@tonic-gate  * defined in _getsp.s
2067c478bd9Sstevel@tonic-gate  */
2077c478bd9Sstevel@tonic-gate extern greg_t _getsp(void);
2087c478bd9Sstevel@tonic-gate 
2097c478bd9Sstevel@tonic-gate /*
2107c478bd9Sstevel@tonic-gate  * defined in _so_setsockopt.s
2117c478bd9Sstevel@tonic-gate  */
2127c478bd9Sstevel@tonic-gate extern int _so_setsockopt(int, int, int, const char *, int);
2137c478bd9Sstevel@tonic-gate 
2147c478bd9Sstevel@tonic-gate /*
2157c478bd9Sstevel@tonic-gate  * defined in _so_getsockopt.s
2167c478bd9Sstevel@tonic-gate  */
2177c478bd9Sstevel@tonic-gate extern int _so_getsockopt(int, int, int, char *, int *);
2187c478bd9Sstevel@tonic-gate 
2197c478bd9Sstevel@tonic-gate /*
2207c478bd9Sstevel@tonic-gate  * defined in lsign.s
2217c478bd9Sstevel@tonic-gate  */
2227c478bd9Sstevel@tonic-gate extern int lsign(dl_t);
2237c478bd9Sstevel@tonic-gate 
224*dd699a3eSToomas Soome /*
225*dd699a3eSToomas Soome  * defined in getctxt.c
226*dd699a3eSToomas Soome  */
227*dd699a3eSToomas Soome extern int _getcontext(ucontext_t *) __RETURNS_TWICE;
228*dd699a3eSToomas Soome 
2297c478bd9Sstevel@tonic-gate /*
2307c478bd9Sstevel@tonic-gate  * defined in ucontext.s
2317c478bd9Sstevel@tonic-gate  */
2327c478bd9Sstevel@tonic-gate extern int __getcontext(ucontext_t *);
2337c478bd9Sstevel@tonic-gate 
2347c478bd9Sstevel@tonic-gate /*
2357c478bd9Sstevel@tonic-gate  * defined in door.s
2367c478bd9Sstevel@tonic-gate  */
2377c478bd9Sstevel@tonic-gate extern int __door_info(int, door_info_t *);
2387c478bd9Sstevel@tonic-gate extern int __door_call(int, door_arg_t *);
2397c478bd9Sstevel@tonic-gate 
2407c478bd9Sstevel@tonic-gate /*
2417c478bd9Sstevel@tonic-gate  * defined in _portfs.s
2427c478bd9Sstevel@tonic-gate  */
2437c478bd9Sstevel@tonic-gate extern int64_t _portfs(int, uintptr_t, uintptr_t, uintptr_t, uintptr_t,
2447c478bd9Sstevel@tonic-gate     uintptr_t);
2457c478bd9Sstevel@tonic-gate 
2467c478bd9Sstevel@tonic-gate /*
2477c478bd9Sstevel@tonic-gate  * defined in xpg4.c
2487c478bd9Sstevel@tonic-gate  */
249a574db85Sraf extern int __xpg4;		/* global */
250a574db85Sraf extern int libc__xpg4;		/* copy of __xpg4, private to libc */
251a574db85Sraf 
252a574db85Sraf /*
253a574db85Sraf  * defined in xpg6.c
254a574db85Sraf  */
255a574db85Sraf extern uint_t __xpg6;		/* global */
256a574db85Sraf extern uint_t libc__xpg6;	/* copy of __xpg6, private to libc */
2577c478bd9Sstevel@tonic-gate 
2587c478bd9Sstevel@tonic-gate /*
2597c478bd9Sstevel@tonic-gate  * defined in port/stdio/doscan.c
2607c478bd9Sstevel@tonic-gate  */
2617c478bd9Sstevel@tonic-gate extern int _doscan(FILE *, const char *, va_list);
2627c478bd9Sstevel@tonic-gate extern int __doscan_u(FILE *, const char *, va_list, int);
2637c478bd9Sstevel@tonic-gate extern int __wdoscan_u(FILE *, const wchar_t *, va_list, int);
2647c478bd9Sstevel@tonic-gate 
2657c478bd9Sstevel@tonic-gate #ifndef _LP64
2667c478bd9Sstevel@tonic-gate /* Flag for _ndoprnt() and _doscan_u() */
2677c478bd9Sstevel@tonic-gate #define	_F_INTMAX32	0x1	/* if set read 4 bytes for u/intmax %j */
2687c478bd9Sstevel@tonic-gate extern int _fprintf_c89(FILE *, const char *, ...);
2697c478bd9Sstevel@tonic-gate extern int _printf_c89(const char *, ...);
2707c478bd9Sstevel@tonic-gate extern int _snprintf_c89(char *, size_t, const char *, ...);
2717c478bd9Sstevel@tonic-gate extern int _sprintf_c89(char *, const char *, ...);
2727c478bd9Sstevel@tonic-gate extern int _wprintf_c89(const wchar_t *, ...);
2737c478bd9Sstevel@tonic-gate extern int _fwprintf_c89(FILE *, const wchar_t *, ...);
2747c478bd9Sstevel@tonic-gate extern int _swprintf_c89(wchar_t *, size_t, const wchar_t *, ...);
2757c478bd9Sstevel@tonic-gate extern int _vfprintf_c89(FILE *, const char *, va_list);
2767c478bd9Sstevel@tonic-gate extern int _vprintf_c89(const char *, va_list);
2777c478bd9Sstevel@tonic-gate extern int _vsnprintf_c89(char *, size_t, const char *, va_list);
2787c478bd9Sstevel@tonic-gate extern int _vsprintf_c89(char *, const char *, va_list);
2797c478bd9Sstevel@tonic-gate extern int _vwprintf_c89(const wchar_t *, va_list);
2807c478bd9Sstevel@tonic-gate extern int _vfwprintf_c89(FILE *, const wchar_t *, va_list);
2817c478bd9Sstevel@tonic-gate extern int _vswprintf_c89(wchar_t *, size_t, const wchar_t *, va_list);
2827c478bd9Sstevel@tonic-gate extern int _scanf_c89(const char *, ...);
2837c478bd9Sstevel@tonic-gate extern int _fscanf_c89(FILE *, const char *, ...);
2847c478bd9Sstevel@tonic-gate extern int _sscanf_c89(const char *, const char *, ...);
2857c478bd9Sstevel@tonic-gate extern int _vscanf_c89(const char *, va_list);
2867c478bd9Sstevel@tonic-gate extern int _vfscanf_c89(FILE *, const char *, va_list);
2877c478bd9Sstevel@tonic-gate extern int _vsscanf_c89(const char *, const char *, va_list);
2887c478bd9Sstevel@tonic-gate extern int _vwscanf_c89(const wchar_t *, va_list);
2897c478bd9Sstevel@tonic-gate extern int _vfwscanf_c89(FILE *, const wchar_t *, va_list);
2907c478bd9Sstevel@tonic-gate extern int _vswscanf_c89(const wchar_t *, const wchar_t *, va_list);
2917c478bd9Sstevel@tonic-gate extern int _wscanf_c89(const wchar_t *, ...);
2927c478bd9Sstevel@tonic-gate extern int _fwscanf_c89(FILE *, const wchar_t *, ...);
2937c478bd9Sstevel@tonic-gate extern int _swscanf_c89(const wchar_t *, const wchar_t *, ...);
2947c478bd9Sstevel@tonic-gate #endif	/*	_LP64	*/
2957c478bd9Sstevel@tonic-gate 
2967c478bd9Sstevel@tonic-gate /*
2977c478bd9Sstevel@tonic-gate  * defined in port/stdio/popen.c
2987c478bd9Sstevel@tonic-gate  */
2997c478bd9Sstevel@tonic-gate extern int _insert(pid_t pid, int fd);
3007c478bd9Sstevel@tonic-gate extern pid_t _delete(int fd);
3017c478bd9Sstevel@tonic-gate 
3027c478bd9Sstevel@tonic-gate /*
3037c478bd9Sstevel@tonic-gate  * defined in port/print/doprnt.c
3047c478bd9Sstevel@tonic-gate  */
3057c478bd9Sstevel@tonic-gate extern ssize_t	_wdoprnt(const wchar_t *, va_list, FILE *);
3067c478bd9Sstevel@tonic-gate 
3077c478bd9Sstevel@tonic-gate /*
3087c478bd9Sstevel@tonic-gate  * defined in fgetwc.c
3097c478bd9Sstevel@tonic-gate  */
3107c478bd9Sstevel@tonic-gate extern wint_t _fgetwc_unlocked(FILE *);
3117c478bd9Sstevel@tonic-gate extern wint_t __getwc_xpg5(FILE *);
3127c478bd9Sstevel@tonic-gate extern wint_t __fgetwc_xpg5(FILE *);
3137c478bd9Sstevel@tonic-gate extern wint_t _getwc(FILE *);
3147c478bd9Sstevel@tonic-gate 
3157c478bd9Sstevel@tonic-gate /*
3167c478bd9Sstevel@tonic-gate  * defined in fputwc.c
3177c478bd9Sstevel@tonic-gate  */
3187c478bd9Sstevel@tonic-gate extern wint_t __putwc_xpg5(wint_t, FILE *);
3197c478bd9Sstevel@tonic-gate extern wint_t _putwc(wint_t, FILE *);
3207c478bd9Sstevel@tonic-gate 
3217c478bd9Sstevel@tonic-gate /*
3227c478bd9Sstevel@tonic-gate  * defined in ungetwc.c
3237c478bd9Sstevel@tonic-gate  */
3247c478bd9Sstevel@tonic-gate extern wint_t	__ungetwc_xpg5(wint_t, FILE *);
3257c478bd9Sstevel@tonic-gate 
326b599bd93SRobert Mustacchi /*
327b599bd93SRobert Mustacchi  * Defined in setlocale.c.
328b599bd93SRobert Mustacchi  */
329b599bd93SRobert Mustacchi extern char *current_locale(locale_t, int);
330b599bd93SRobert Mustacchi 
33100efb5e1SYuri Pankov /*
33200efb5e1SYuri Pankov  * defined in set_constraint_handler_s.c.
33300efb5e1SYuri Pankov  */
33400efb5e1SYuri Pankov extern void __throw_constraint_handler_s(const char *_RESTRICT_KYWD, int);
33500efb5e1SYuri Pankov 
33600efb5e1SYuri Pankov /*
33700efb5e1SYuri Pankov  * defined in assfail.c.
33800efb5e1SYuri Pankov  */
33900efb5e1SYuri Pankov extern void common_panic(const char *, const char *);
34000efb5e1SYuri Pankov 
3410ac311baSRobert Mustacchi /*
3420ac311baSRobert Mustacchi  * defined in mbrtowc.c.
3430ac311baSRobert Mustacchi  */
3440ac311baSRobert Mustacchi extern size_t mbrtowc_nz_l(wchar_t *_RESTRICT_KYWD, const char *_RESTRICT_KYWD,
3450ac311baSRobert Mustacchi     size_t, mbstate_t *_RESTRICT_KYWD, locale_t);
3460ac311baSRobert Mustacchi extern size_t mbrtowc_nz(wchar_t *_RESTRICT_KYWD, const char *_RESTRICT_KYWD,
3470ac311baSRobert Mustacchi     size_t, mbstate_t *_RESTRICT_KYWD);
3480ac311baSRobert Mustacchi 
3497c478bd9Sstevel@tonic-gate #ifdef	__cplusplus
3507c478bd9Sstevel@tonic-gate }
3517c478bd9Sstevel@tonic-gate #endif
3527c478bd9Sstevel@tonic-gate 
3537c478bd9Sstevel@tonic-gate #endif /* _LIBC_H */
354