blob: ddc2948c0da94bc91379ff12c1980033d30c12b1 [file] [log] [blame]
lh9ed821d2023-04-07 01:36:19 -07001/* -mlong-double-64 compatibility mode for stdio functions.
2 Copyright (C) 2006-2015 Free Software Foundation, Inc.
3 This file is part of the GNU C Library.
4
5 The GNU C Library is free software; you can redistribute it and/or
6 modify it under the terms of the GNU Lesser General Public
7 License as published by the Free Software Foundation; either
8 version 2.1 of the License, or (at your option) any later version.
9
10 The GNU C Library is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 Lesser General Public License for more details.
14
15 You should have received a copy of the GNU Lesser General Public
16 License along with the GNU C Library; if not, see
17 <http://www.gnu.org/licenses/>. */
18
19#ifndef _STDIO_H
20# error "Never include <bits/stdio-ldbl.h> directly; use <stdio.h> instead."
21#endif
22
23__BEGIN_NAMESPACE_STD
24__LDBL_REDIR_DECL (fprintf)
25__LDBL_REDIR_DECL (printf)
26__LDBL_REDIR_DECL (sprintf)
27__LDBL_REDIR_DECL (vfprintf)
28__LDBL_REDIR_DECL (vprintf)
29__LDBL_REDIR_DECL (vsprintf)
30#if defined __USE_ISOC99 && !defined __USE_GNU \
31 && !defined __REDIRECT \
32 && (defined __STRICT_ANSI__ || defined __USE_XOPEN2K)
33__LDBL_REDIR1_DECL (fscanf, __nldbl___isoc99_fscanf)
34__LDBL_REDIR1_DECL (scanf, __nldbl___isoc99_scanf)
35__LDBL_REDIR1_DECL (sscanf, __nldbl___isoc99_sscanf)
36#else
37__LDBL_REDIR_DECL (fscanf)
38__LDBL_REDIR_DECL (scanf)
39__LDBL_REDIR_DECL (sscanf)
40#endif
41__END_NAMESPACE_STD
42
43#if defined __USE_ISOC99 || defined __USE_UNIX98
44__BEGIN_NAMESPACE_C99
45__LDBL_REDIR_DECL (snprintf)
46__LDBL_REDIR_DECL (vsnprintf)
47__END_NAMESPACE_C99
48#endif
49
50#ifdef __USE_ISOC99
51__BEGIN_NAMESPACE_C99
52# if !defined __USE_GNU && !defined __REDIRECT \
53 && (defined __STRICT_ANSI__ || defined __USE_XOPEN2K)
54__LDBL_REDIR1_DECL (vfscanf, __nldbl___isoc99_vfscanf)
55__LDBL_REDIR1_DECL (vscanf, __nldbl___isoc99_vscanf)
56__LDBL_REDIR1_DECL (vsscanf, __nldbl___isoc99_vsscanf)
57# else
58__LDBL_REDIR_DECL (vfscanf)
59__LDBL_REDIR_DECL (vsscanf)
60__LDBL_REDIR_DECL (vscanf)
61# endif
62__END_NAMESPACE_C99
63#endif
64
65#ifdef __USE_XOPEN2K8
66__LDBL_REDIR_DECL (vdprintf)
67__LDBL_REDIR_DECL (dprintf)
68#endif
69
70#ifdef __USE_GNU
71__LDBL_REDIR_DECL (vasprintf)
72__LDBL_REDIR_DECL (__asprintf)
73__LDBL_REDIR_DECL (asprintf)
74__LDBL_REDIR_DECL (obstack_printf)
75__LDBL_REDIR_DECL (obstack_vprintf)
76#endif
77
78#if __USE_FORTIFY_LEVEL > 0 && defined __fortify_function
79__LDBL_REDIR_DECL (__sprintf_chk)
80__LDBL_REDIR_DECL (__vsprintf_chk)
81# if defined __USE_ISOC99 || defined __USE_UNIX98
82__LDBL_REDIR_DECL (__snprintf_chk)
83__LDBL_REDIR_DECL (__vsnprintf_chk)
84# endif
85# if __USE_FORTIFY_LEVEL > 1
86__LDBL_REDIR_DECL (__fprintf_chk)
87__LDBL_REDIR_DECL (__printf_chk)
88__LDBL_REDIR_DECL (__vfprintf_chk)
89__LDBL_REDIR_DECL (__vprintf_chk)
90# ifdef __USE_XOPEN2K8
91__LDBL_REDIR_DECL (__dprintf_chk)
92__LDBL_REDIR_DECL (__vdprintf_chk)
93# endif
94# ifdef __USE_GNU
95__LDBL_REDIR_DECL (__asprintf_chk)
96__LDBL_REDIR_DECL (__vasprintf_chk)
97__LDBL_REDIR_DECL (__obstack_printf_chk)
98__LDBL_REDIR_DECL (__obstack_vprintf_chk)
99# endif
100# endif
101#endif