libio.h 17 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524
  1. /* Copyright (C) 1991-2016 Free Software Foundation, Inc.
  2. This file is part of the GNU C Library.
  3. Written by Per Bothner <bothner@cygnus.com>.
  4. The GNU C Library is free software; you can redistribute it and/or
  5. modify it under the terms of the GNU Lesser General Public
  6. License as published by the Free Software Foundation; either
  7. version 2.1 of the License, or (at your option) any later version.
  8. The GNU C Library is distributed in the hope that it will be useful,
  9. but WITHOUT ANY WARRANTY; without even the implied warranty of
  10. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  11. Lesser General Public License for more details.
  12. You should have received a copy of the GNU Lesser General Public
  13. License along with the GNU C Library; if not, see
  14. <http://www.gnu.org/licenses/>.
  15. As a special exception, if you link the code in this file with
  16. files compiled with a GNU compiler to produce an executable,
  17. that does not cause the resulting executable to be covered by
  18. the GNU Lesser General Public License. This exception does not
  19. however invalidate any other reasons why the executable file
  20. might be covered by the GNU Lesser General Public License.
  21. This exception applies to code released by its copyright holders
  22. in files containing the exception. */
  23. #ifndef _IO_STDIO_H
  24. #define _IO_STDIO_H
  25. #include <_G_config.h>
  26. /* ALL of these should be defined in _G_config.h */
  27. #define _IO_fpos_t _G_fpos_t
  28. #define _IO_fpos64_t _G_fpos64_t
  29. #define _IO_size_t size_t
  30. #define _IO_ssize_t __ssize_t
  31. #define _IO_off_t __off_t
  32. #define _IO_off64_t __off64_t
  33. #define _IO_pid_t __pid_t
  34. #define _IO_uid_t __uid_t
  35. #define _IO_iconv_t _G_iconv_t
  36. #define _IO_HAVE_ST_BLKSIZE _G_HAVE_ST_BLKSIZE
  37. #define _IO_BUFSIZ _G_BUFSIZ
  38. #define _IO_va_list _G_va_list
  39. #define _IO_wint_t wint_t
  40. /* This define avoids name pollution if we're using GNU stdarg.h */
  41. #define __need___va_list
  42. #include <stdarg.h>
  43. #ifdef __GNUC_VA_LIST
  44. # undef _IO_va_list
  45. # define _IO_va_list __gnuc_va_list
  46. #endif /* __GNUC_VA_LIST */
  47. #ifndef __P
  48. # include <sys/cdefs.h>
  49. #endif /*!__P*/
  50. #define _IO_UNIFIED_JUMPTABLES 1
  51. #ifndef EOF
  52. # define EOF (-1)
  53. #endif
  54. #ifndef NULL
  55. # if defined __GNUG__ && \
  56. (__GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 8))
  57. # define NULL (__null)
  58. # else
  59. # if !defined(__cplusplus)
  60. # define NULL ((void*)0)
  61. # else
  62. # define NULL (0)
  63. # endif
  64. # endif
  65. #endif
  66. #define _IOS_INPUT 1
  67. #define _IOS_OUTPUT 2
  68. #define _IOS_ATEND 4
  69. #define _IOS_APPEND 8
  70. #define _IOS_TRUNC 16
  71. #define _IOS_NOCREATE 32
  72. #define _IOS_NOREPLACE 64
  73. #define _IOS_BIN 128
  74. /* Magic numbers and bits for the _flags field.
  75. The magic numbers use the high-order bits of _flags;
  76. the remaining bits are available for variable flags.
  77. Note: The magic numbers must all be negative if stdio
  78. emulation is desired. */
  79. #define _IO_MAGIC 0xFBAD0000 /* Magic number */
  80. #define _OLD_STDIO_MAGIC 0xFABC0000 /* Emulate old stdio. */
  81. #define _IO_MAGIC_MASK 0xFFFF0000
  82. #define _IO_USER_BUF 1 /* User owns buffer; don't delete it on close. */
  83. #define _IO_UNBUFFERED 2
  84. #define _IO_NO_READS 4 /* Reading not allowed */
  85. #define _IO_NO_WRITES 8 /* Writing not allowd */
  86. #define _IO_EOF_SEEN 0x10
  87. #define _IO_ERR_SEEN 0x20
  88. #define _IO_DELETE_DONT_CLOSE 0x40 /* Don't call close(_fileno) on cleanup. */
  89. #define _IO_LINKED 0x80 /* Set if linked (using _chain) to streambuf::_list_all.*/
  90. #define _IO_IN_BACKUP 0x100
  91. #define _IO_LINE_BUF 0x200
  92. #define _IO_TIED_PUT_GET 0x400 /* Set if put and get pointer logicly tied. */
  93. #define _IO_CURRENTLY_PUTTING 0x800
  94. #define _IO_IS_APPENDING 0x1000
  95. #define _IO_IS_FILEBUF 0x2000
  96. #define _IO_BAD_SEEN 0x4000
  97. #define _IO_USER_LOCK 0x8000
  98. #define _IO_FLAGS2_MMAP 1
  99. #define _IO_FLAGS2_NOTCANCEL 2
  100. #ifdef _LIBC
  101. # define _IO_FLAGS2_FORTIFY 4
  102. #endif
  103. #define _IO_FLAGS2_USER_WBUF 8
  104. #ifdef _LIBC
  105. # define _IO_FLAGS2_SCANF_STD 16
  106. # define _IO_FLAGS2_NOCLOSE 32
  107. # define _IO_FLAGS2_CLOEXEC 64
  108. #endif
  109. /* These are "formatting flags" matching the iostream fmtflags enum values. */
  110. #define _IO_SKIPWS 01
  111. #define _IO_LEFT 02
  112. #define _IO_RIGHT 04
  113. #define _IO_INTERNAL 010
  114. #define _IO_DEC 020
  115. #define _IO_OCT 040
  116. #define _IO_HEX 0100
  117. #define _IO_SHOWBASE 0200
  118. #define _IO_SHOWPOINT 0400
  119. #define _IO_UPPERCASE 01000
  120. #define _IO_SHOWPOS 02000
  121. #define _IO_SCIENTIFIC 04000
  122. #define _IO_FIXED 010000
  123. #define _IO_UNITBUF 020000
  124. #define _IO_STDIO 040000
  125. #define _IO_DONT_CLOSE 0100000
  126. #define _IO_BOOLALPHA 0200000
  127. struct _IO_jump_t; struct _IO_FILE;
  128. /* Handle lock. */
  129. #ifdef _IO_MTSAFE_IO
  130. /* _IO_lock_t defined in internal headers during the glibc build. */
  131. #else
  132. typedef void _IO_lock_t;
  133. #endif
  134. /* A streammarker remembers a position in a buffer. */
  135. struct _IO_marker {
  136. struct _IO_marker *_next;
  137. struct _IO_FILE *_sbuf;
  138. /* If _pos >= 0
  139. it points to _buf->Gbase()+_pos. FIXME comment */
  140. /* if _pos < 0, it points to _buf->eBptr()+_pos. FIXME comment */
  141. int _pos;
  142. #if 0
  143. void set_streampos(streampos sp) { _spos = sp; }
  144. void set_offset(int offset) { _pos = offset; _spos = (streampos)(-2); }
  145. public:
  146. streammarker(streambuf *sb);
  147. ~streammarker();
  148. int saving() { return _spos == -2; }
  149. int delta(streammarker&);
  150. int delta();
  151. #endif
  152. };
  153. /* This is the structure from the libstdc++ codecvt class. */
  154. enum __codecvt_result
  155. {
  156. __codecvt_ok,
  157. __codecvt_partial,
  158. __codecvt_error,
  159. __codecvt_noconv
  160. };
  161. #if defined _LIBC || defined _GLIBCPP_USE_WCHAR_T
  162. /* The order of the elements in the following struct must match the order
  163. of the virtual functions in the libstdc++ codecvt class. */
  164. struct _IO_codecvt
  165. {
  166. void (*__codecvt_destr) (struct _IO_codecvt *);
  167. enum __codecvt_result (*__codecvt_do_out) (struct _IO_codecvt *,
  168. __mbstate_t *,
  169. const wchar_t *,
  170. const wchar_t *,
  171. const wchar_t **, char *,
  172. char *, char **);
  173. enum __codecvt_result (*__codecvt_do_unshift) (struct _IO_codecvt *,
  174. __mbstate_t *, char *,
  175. char *, char **);
  176. enum __codecvt_result (*__codecvt_do_in) (struct _IO_codecvt *,
  177. __mbstate_t *,
  178. const char *, const char *,
  179. const char **, wchar_t *,
  180. wchar_t *, wchar_t **);
  181. int (*__codecvt_do_encoding) (struct _IO_codecvt *);
  182. int (*__codecvt_do_always_noconv) (struct _IO_codecvt *);
  183. int (*__codecvt_do_length) (struct _IO_codecvt *, __mbstate_t *,
  184. const char *, const char *, _IO_size_t);
  185. int (*__codecvt_do_max_length) (struct _IO_codecvt *);
  186. _IO_iconv_t __cd_in;
  187. _IO_iconv_t __cd_out;
  188. };
  189. /* Extra data for wide character streams. */
  190. struct _IO_wide_data
  191. {
  192. wchar_t *_IO_read_ptr; /* Current read pointer */
  193. wchar_t *_IO_read_end; /* End of get area. */
  194. wchar_t *_IO_read_base; /* Start of putback+get area. */
  195. wchar_t *_IO_write_base; /* Start of put area. */
  196. wchar_t *_IO_write_ptr; /* Current put pointer. */
  197. wchar_t *_IO_write_end; /* End of put area. */
  198. wchar_t *_IO_buf_base; /* Start of reserve area. */
  199. wchar_t *_IO_buf_end; /* End of reserve area. */
  200. /* The following fields are used to support backing up and undo. */
  201. wchar_t *_IO_save_base; /* Pointer to start of non-current get area. */
  202. wchar_t *_IO_backup_base; /* Pointer to first valid character of
  203. backup area */
  204. wchar_t *_IO_save_end; /* Pointer to end of non-current get area. */
  205. __mbstate_t _IO_state;
  206. __mbstate_t _IO_last_state;
  207. struct _IO_codecvt _codecvt;
  208. wchar_t _shortbuf[1];
  209. const struct _IO_jump_t *_wide_vtable;
  210. };
  211. #endif
  212. struct _IO_FILE {
  213. int _flags; /* High-order word is _IO_MAGIC; rest is flags. */
  214. #define _IO_file_flags _flags
  215. /* The following pointers correspond to the C++ streambuf protocol. */
  216. /* Note: Tk uses the _IO_read_ptr and _IO_read_end fields directly. */
  217. char* _IO_read_ptr; /* Current read pointer */
  218. char* _IO_read_end; /* End of get area. */
  219. char* _IO_read_base; /* Start of putback+get area. */
  220. char* _IO_write_base; /* Start of put area. */
  221. char* _IO_write_ptr; /* Current put pointer. */
  222. char* _IO_write_end; /* End of put area. */
  223. char* _IO_buf_base; /* Start of reserve area. */
  224. char* _IO_buf_end; /* End of reserve area. */
  225. /* The following fields are used to support backing up and undo. */
  226. char *_IO_save_base; /* Pointer to start of non-current get area. */
  227. char *_IO_backup_base; /* Pointer to first valid character of backup area */
  228. char *_IO_save_end; /* Pointer to end of non-current get area. */
  229. struct _IO_marker *_markers;
  230. struct _IO_FILE *_chain;
  231. int _fileno;
  232. #if 0
  233. int _blksize;
  234. #else
  235. int _flags2;
  236. #endif
  237. _IO_off_t _old_offset; /* This used to be _offset but it's too small. */
  238. #define __HAVE_COLUMN /* temporary */
  239. /* 1+column number of pbase(); 0 is unknown. */
  240. unsigned short _cur_column;
  241. signed char _vtable_offset;
  242. char _shortbuf[1];
  243. /* char* _save_gptr; char* _save_egptr; */
  244. _IO_lock_t *_lock;
  245. #ifdef _IO_USE_OLD_IO_FILE
  246. };
  247. struct _IO_FILE_complete
  248. {
  249. struct _IO_FILE _file;
  250. #endif
  251. #if defined _G_IO_IO_FILE_VERSION && _G_IO_IO_FILE_VERSION == 0x20001
  252. _IO_off64_t _offset;
  253. # if defined _LIBC || defined _GLIBCPP_USE_WCHAR_T
  254. /* Wide character stream stuff. */
  255. struct _IO_codecvt *_codecvt;
  256. struct _IO_wide_data *_wide_data;
  257. struct _IO_FILE *_freeres_list;
  258. void *_freeres_buf;
  259. # else
  260. void *__pad1;
  261. void *__pad2;
  262. void *__pad3;
  263. void *__pad4;
  264. # endif
  265. size_t __pad5;
  266. int _mode;
  267. /* Make sure we don't get into trouble again. */
  268. char _unused2[15 * sizeof (int) - 4 * sizeof (void *) - sizeof (size_t)];
  269. #endif
  270. };
  271. #ifndef __cplusplus
  272. typedef struct _IO_FILE _IO_FILE;
  273. #endif
  274. struct _IO_FILE_plus;
  275. extern struct _IO_FILE_plus _IO_2_1_stdin_;
  276. extern struct _IO_FILE_plus _IO_2_1_stdout_;
  277. extern struct _IO_FILE_plus _IO_2_1_stderr_;
  278. #ifndef _LIBC
  279. #define _IO_stdin ((_IO_FILE*)(&_IO_2_1_stdin_))
  280. #define _IO_stdout ((_IO_FILE*)(&_IO_2_1_stdout_))
  281. #define _IO_stderr ((_IO_FILE*)(&_IO_2_1_stderr_))
  282. #else
  283. extern _IO_FILE *_IO_stdin attribute_hidden;
  284. extern _IO_FILE *_IO_stdout attribute_hidden;
  285. extern _IO_FILE *_IO_stderr attribute_hidden;
  286. #endif
  287. /* Functions to do I/O and file management for a stream. */
  288. /* Read NBYTES bytes from COOKIE into a buffer pointed to by BUF.
  289. Return number of bytes read. */
  290. typedef __ssize_t __io_read_fn (void *__cookie, char *__buf, size_t __nbytes);
  291. /* Write N bytes pointed to by BUF to COOKIE. Write all N bytes
  292. unless there is an error. Return number of bytes written. If
  293. there is an error, return 0 and do not write anything. If the file
  294. has been opened for append (__mode.__append set), then set the file
  295. pointer to the end of the file and then do the write; if not, just
  296. write at the current file pointer. */
  297. typedef __ssize_t __io_write_fn (void *__cookie, const char *__buf,
  298. size_t __n);
  299. /* Move COOKIE's file position to *POS bytes from the
  300. beginning of the file (if W is SEEK_SET),
  301. the current position (if W is SEEK_CUR),
  302. or the end of the file (if W is SEEK_END).
  303. Set *POS to the new file position.
  304. Returns zero if successful, nonzero if not. */
  305. typedef int __io_seek_fn (void *__cookie, _IO_off64_t *__pos, int __w);
  306. /* Close COOKIE. */
  307. typedef int __io_close_fn (void *__cookie);
  308. #ifdef _GNU_SOURCE
  309. /* User-visible names for the above. */
  310. typedef __io_read_fn cookie_read_function_t;
  311. typedef __io_write_fn cookie_write_function_t;
  312. typedef __io_seek_fn cookie_seek_function_t;
  313. typedef __io_close_fn cookie_close_function_t;
  314. /* The structure with the cookie function pointers. */
  315. typedef struct
  316. {
  317. __io_read_fn *read; /* Read bytes. */
  318. __io_write_fn *write; /* Write bytes. */
  319. __io_seek_fn *seek; /* Seek/tell file position. */
  320. __io_close_fn *close; /* Close file. */
  321. } _IO_cookie_io_functions_t;
  322. typedef _IO_cookie_io_functions_t cookie_io_functions_t;
  323. struct _IO_cookie_file;
  324. /* Initialize one of those. */
  325. extern void _IO_cookie_init (struct _IO_cookie_file *__cfile, int __read_write,
  326. void *__cookie, _IO_cookie_io_functions_t __fns);
  327. #endif
  328. #ifdef __cplusplus
  329. extern "C" {
  330. #endif
  331. extern int __underflow (_IO_FILE *);
  332. extern int __uflow (_IO_FILE *);
  333. extern int __overflow (_IO_FILE *, int);
  334. #if defined _LIBC || defined _GLIBCPP_USE_WCHAR_T
  335. extern _IO_wint_t __wunderflow (_IO_FILE *);
  336. extern _IO_wint_t __wuflow (_IO_FILE *);
  337. extern _IO_wint_t __woverflow (_IO_FILE *, _IO_wint_t);
  338. #endif
  339. #if __GNUC__ >= 3
  340. # define _IO_BE(expr, res) __builtin_expect ((expr), res)
  341. #else
  342. # define _IO_BE(expr, res) (expr)
  343. #endif
  344. #define _IO_getc_unlocked(_fp) \
  345. (_IO_BE ((_fp)->_IO_read_ptr >= (_fp)->_IO_read_end, 0) \
  346. ? __uflow (_fp) : *(unsigned char *) (_fp)->_IO_read_ptr++)
  347. #define _IO_peekc_unlocked(_fp) \
  348. (_IO_BE ((_fp)->_IO_read_ptr >= (_fp)->_IO_read_end, 0) \
  349. && __underflow (_fp) == EOF ? EOF \
  350. : *(unsigned char *) (_fp)->_IO_read_ptr)
  351. #define _IO_putc_unlocked(_ch, _fp) \
  352. (_IO_BE ((_fp)->_IO_write_ptr >= (_fp)->_IO_write_end, 0) \
  353. ? __overflow (_fp, (unsigned char) (_ch)) \
  354. : (unsigned char) (*(_fp)->_IO_write_ptr++ = (_ch)))
  355. #if defined _LIBC || defined _GLIBCPP_USE_WCHAR_T
  356. # define _IO_getwc_unlocked(_fp) \
  357. (_IO_BE ((_fp)->_wide_data == NULL \
  358. || ((_fp)->_wide_data->_IO_read_ptr \
  359. >= (_fp)->_wide_data->_IO_read_end), 0) \
  360. ? __wuflow (_fp) : (_IO_wint_t) *(_fp)->_wide_data->_IO_read_ptr++)
  361. # define _IO_putwc_unlocked(_wch, _fp) \
  362. (_IO_BE ((_fp)->_wide_data == NULL \
  363. || ((_fp)->_wide_data->_IO_write_ptr \
  364. >= (_fp)->_wide_data->_IO_write_end), 0) \
  365. ? __woverflow (_fp, _wch) \
  366. : (_IO_wint_t) (*(_fp)->_wide_data->_IO_write_ptr++ = (_wch)))
  367. #endif
  368. #define _IO_feof_unlocked(__fp) (((__fp)->_flags & _IO_EOF_SEEN) != 0)
  369. #define _IO_ferror_unlocked(__fp) (((__fp)->_flags & _IO_ERR_SEEN) != 0)
  370. extern int _IO_getc (_IO_FILE *__fp);
  371. extern int _IO_putc (int __c, _IO_FILE *__fp);
  372. extern int _IO_feof (_IO_FILE *__fp) __THROW;
  373. extern int _IO_ferror (_IO_FILE *__fp) __THROW;
  374. extern int _IO_peekc_locked (_IO_FILE *__fp);
  375. /* This one is for Emacs. */
  376. #define _IO_PENDING_OUTPUT_COUNT(_fp) \
  377. ((_fp)->_IO_write_ptr - (_fp)->_IO_write_base)
  378. extern void _IO_flockfile (_IO_FILE *) __THROW;
  379. extern void _IO_funlockfile (_IO_FILE *) __THROW;
  380. extern int _IO_ftrylockfile (_IO_FILE *) __THROW;
  381. #ifdef _IO_MTSAFE_IO
  382. # define _IO_peekc(_fp) _IO_peekc_locked (_fp)
  383. # define _IO_flockfile(_fp) \
  384. if (((_fp)->_flags & _IO_USER_LOCK) == 0) _IO_flockfile (_fp)
  385. # define _IO_funlockfile(_fp) \
  386. if (((_fp)->_flags & _IO_USER_LOCK) == 0) _IO_funlockfile (_fp)
  387. #else
  388. # define _IO_peekc(_fp) _IO_peekc_unlocked (_fp)
  389. # define _IO_flockfile(_fp) /**/
  390. # define _IO_funlockfile(_fp) /**/
  391. # define _IO_ftrylockfile(_fp) /**/
  392. # define _IO_cleanup_region_start(_fct, _fp) /**/
  393. # define _IO_cleanup_region_end(_Doit) /**/
  394. #endif /* !_IO_MTSAFE_IO */
  395. extern int _IO_vfscanf (_IO_FILE * __restrict, const char * __restrict,
  396. _IO_va_list, int *__restrict);
  397. extern int _IO_vfprintf (_IO_FILE *__restrict, const char *__restrict,
  398. _IO_va_list);
  399. extern _IO_ssize_t _IO_padn (_IO_FILE *, int, _IO_ssize_t);
  400. extern _IO_size_t _IO_sgetn (_IO_FILE *, void *, _IO_size_t);
  401. extern _IO_off64_t _IO_seekoff (_IO_FILE *, _IO_off64_t, int, int);
  402. extern _IO_off64_t _IO_seekpos (_IO_FILE *, _IO_off64_t, int);
  403. extern void _IO_free_backup_area (_IO_FILE *) __THROW;
  404. #if defined _LIBC || defined _GLIBCPP_USE_WCHAR_T
  405. extern _IO_wint_t _IO_getwc (_IO_FILE *__fp);
  406. extern _IO_wint_t _IO_putwc (wchar_t __wc, _IO_FILE *__fp);
  407. extern int _IO_fwide (_IO_FILE *__fp, int __mode) __THROW;
  408. # if __GNUC__ >= 2
  409. /* While compiling glibc we have to handle compatibility with very old
  410. versions. */
  411. # if defined _LIBC && defined SHARED
  412. # include <shlib-compat.h>
  413. # if SHLIB_COMPAT (libc, GLIBC_2_0, GLIBC_2_1)
  414. # define _IO_fwide_maybe_incompatible \
  415. (__builtin_expect (&_IO_stdin_used == NULL, 0))
  416. extern const int _IO_stdin_used;
  417. weak_extern (_IO_stdin_used);
  418. # endif
  419. # endif
  420. # ifndef _IO_fwide_maybe_incompatible
  421. # define _IO_fwide_maybe_incompatible (0)
  422. # endif
  423. /* A special optimized version of the function above. It optimizes the
  424. case of initializing an unoriented byte stream. */
  425. # define _IO_fwide(__fp, __mode) \
  426. ({ int __result = (__mode); \
  427. if (__result < 0 && ! _IO_fwide_maybe_incompatible) \
  428. { \
  429. if ((__fp)->_mode == 0) \
  430. /* We know that all we have to do is to set the flag. */ \
  431. (__fp)->_mode = -1; \
  432. __result = (__fp)->_mode; \
  433. } \
  434. else if (__builtin_constant_p (__mode) && (__mode) == 0) \
  435. __result = _IO_fwide_maybe_incompatible ? -1 : (__fp)->_mode; \
  436. else \
  437. __result = _IO_fwide (__fp, __result); \
  438. __result; })
  439. # endif
  440. extern int _IO_vfwscanf (_IO_FILE * __restrict, const wchar_t * __restrict,
  441. _IO_va_list, int *__restrict);
  442. extern int _IO_vfwprintf (_IO_FILE *__restrict, const wchar_t *__restrict,
  443. _IO_va_list);
  444. extern _IO_ssize_t _IO_wpadn (_IO_FILE *, wint_t, _IO_ssize_t);
  445. extern void _IO_free_wbackup_area (_IO_FILE *) __THROW;
  446. #endif
  447. #ifdef __LDBL_COMPAT
  448. # include <bits/libio-ldbl.h>
  449. #endif
  450. #ifdef __cplusplus
  451. }
  452. #endif
  453. #endif /* _IO_STDIO_H */