0e9272f7a4fdba14d211bbe8342f0e6bc11eb3fc
[debian/tar] / gnu / locale.in.h
1 /* -*- buffer-read-only: t -*- vi: set ro: */
2 /* DO NOT EDIT! GENERATED AUTOMATICALLY! */
3 /* A POSIX <locale.h>.
4    Copyright (C) 2007-2013 Free Software Foundation, Inc.
5
6    This program is free software: you can redistribute it and/or modify
7    it under the terms of the GNU General Public License as published by
8    the Free Software Foundation; either version 3 of the License, or
9    (at your option) any later version.
10
11    This program is distributed in the hope that it will be useful,
12    but WITHOUT ANY WARRANTY; without even the implied warranty of
13    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14    GNU General Public License for more details.
15
16    You should have received a copy of the GNU General Public License
17    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
18
19 #if __GNUC__ >= 3
20 @PRAGMA_SYSTEM_HEADER@
21 #endif
22 @PRAGMA_COLUMNS@
23
24 #ifdef _GL_ALREADY_INCLUDING_LOCALE_H
25
26 /* Special invocation conventions to handle Solaris header files
27    (through Solaris 10) when combined with gettext's libintl.h.  */
28
29 #@INCLUDE_NEXT@ @NEXT_LOCALE_H@
30
31 #else
32 /* Normal invocation convention.  */
33
34 #ifndef _@GUARD_PREFIX@_LOCALE_H
35
36 #define _GL_ALREADY_INCLUDING_LOCALE_H
37
38 /* The include_next requires a split double-inclusion guard.  */
39 #@INCLUDE_NEXT@ @NEXT_LOCALE_H@
40
41 #undef _GL_ALREADY_INCLUDING_LOCALE_H
42
43 #ifndef _@GUARD_PREFIX@_LOCALE_H
44 #define _@GUARD_PREFIX@_LOCALE_H
45
46 /* NetBSD 5.0 mis-defines NULL.  */
47 #include <stddef.h>
48
49 /* Mac OS X 10.5 defines the locale_t type in <xlocale.h>.  */
50 #if @HAVE_XLOCALE_H@
51 # include <xlocale.h>
52 #endif
53
54 /* The definitions of _GL_FUNCDECL_RPL etc. are copied here.  */
55
56 /* The definition of _GL_ARG_NONNULL is copied here.  */
57
58 /* The definition of _GL_WARN_ON_USE is copied here.  */
59
60 /* The LC_MESSAGES locale category is specified in POSIX, but not in ISO C.
61    On systems that don't define it, use the same value as GNU libintl.  */
62 #if !defined LC_MESSAGES
63 # define LC_MESSAGES 1729
64 #endif
65
66 /* Bionic libc's 'struct lconv' is just a dummy.  */
67 #if @REPLACE_STRUCT_LCONV@
68 # define lconv rpl_lconv
69 struct lconv
70 {
71   /* All 'char *' are actually 'const char *'.  */
72
73   /* Members that depend on the LC_NUMERIC category of the locale.  See
74      <http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap07.html#tag_07_03_04> */
75
76   /* Symbol used as decimal point.  */
77   char *decimal_point;
78   /* Symbol used to separate groups of digits to the left of the decimal
79      point.  */
80   char *thousands_sep;
81   /* Definition of the size of groups of digits to the left of the decimal
82      point.  */
83   char *grouping;
84
85   /* Members that depend on the LC_MONETARY category of the locale.  See
86      <http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap07.html#tag_07_03_03> */
87
88   /* Symbol used as decimal point.  */
89   char *mon_decimal_point;
90   /* Symbol used to separate groups of digits to the left of the decimal
91      point.  */
92   char *mon_thousands_sep;
93   /* Definition of the size of groups of digits to the left of the decimal
94      point.  */
95   char *mon_grouping;
96   /* Sign used to indicate a value >= 0.  */
97   char *positive_sign;
98   /* Sign used to indicate a value < 0.  */
99   char *negative_sign;
100
101   /* For formatting local currency.  */
102   /* Currency symbol (3 characters) followed by separator (1 character).  */
103   char *currency_symbol;
104   /* Number of digits after the decimal point.  */
105   char frac_digits;
106   /* For values >= 0: 1 if the currency symbol precedes the number, 0 if it
107      comes after the number.  */
108   char p_cs_precedes;
109   /* For values >= 0: Position of the sign.  */
110   char p_sign_posn;
111   /* For values >= 0: Placement of spaces between currency symbol, sign, and
112      number.  */
113   char p_sep_by_space;
114   /* For values < 0: 1 if the currency symbol precedes the number, 0 if it
115      comes after the number.  */
116   char n_cs_precedes;
117   /* For values < 0: Position of the sign.  */
118   char n_sign_posn;
119   /* For values < 0: Placement of spaces between currency symbol, sign, and
120      number.  */
121   char n_sep_by_space;
122
123   /* For formatting international currency.  */
124   /* Currency symbol (3 characters) followed by separator (1 character).  */
125   char *int_curr_symbol;
126   /* Number of digits after the decimal point.  */
127   char int_frac_digits;
128   /* For values >= 0: 1 if the currency symbol precedes the number, 0 if it
129      comes after the number.  */
130   char int_p_cs_precedes;
131   /* For values >= 0: Position of the sign.  */
132   char int_p_sign_posn;
133   /* For values >= 0: Placement of spaces between currency symbol, sign, and
134      number.  */
135   char int_p_sep_by_space;
136   /* For values < 0: 1 if the currency symbol precedes the number, 0 if it
137      comes after the number.  */
138   char int_n_cs_precedes;
139   /* For values < 0: Position of the sign.  */
140   char int_n_sign_posn;
141   /* For values < 0: Placement of spaces between currency symbol, sign, and
142      number.  */
143   char int_n_sep_by_space;
144 };
145 #endif
146
147 #if @GNULIB_LOCALECONV@
148 # if @REPLACE_LOCALECONV@
149 #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
150 #   undef localeconv
151 #   define localeconv rpl_localeconv
152 #  endif
153 _GL_FUNCDECL_RPL (localeconv, struct lconv *, (void));
154 _GL_CXXALIAS_RPL (localeconv, struct lconv *, (void));
155 # else
156 _GL_CXXALIAS_SYS (localeconv, struct lconv *, (void));
157 # endif
158 _GL_CXXALIASWARN (localeconv);
159 #elif @REPLACE_STRUCT_LCONV@
160 # undef localeconv
161 # define localeconv localeconv_used_without_requesting_gnulib_module_localeconv
162 #elif defined GNULIB_POSIXCHECK
163 # undef localeconv
164 # if HAVE_RAW_DECL_LOCALECONV
165 _GL_WARN_ON_USE (localeconv,
166                  "localeconv returns too few information on some platforms - "
167                  "use gnulib module localeconv for portability");
168 # endif
169 #endif
170
171 #if @GNULIB_SETLOCALE@
172 # if @REPLACE_SETLOCALE@
173 #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
174 #   undef setlocale
175 #   define setlocale rpl_setlocale
176 #   define GNULIB_defined_setlocale 1
177 #  endif
178 _GL_FUNCDECL_RPL (setlocale, char *, (int category, const char *locale));
179 _GL_CXXALIAS_RPL (setlocale, char *, (int category, const char *locale));
180 # else
181 _GL_CXXALIAS_SYS (setlocale, char *, (int category, const char *locale));
182 # endif
183 _GL_CXXALIASWARN (setlocale);
184 #elif defined GNULIB_POSIXCHECK
185 # undef setlocale
186 # if HAVE_RAW_DECL_SETLOCALE
187 _GL_WARN_ON_USE (setlocale, "setlocale works differently on native Windows - "
188                  "use gnulib module setlocale for portability");
189 # endif
190 #endif
191
192 #if @GNULIB_DUPLOCALE@
193 # if @REPLACE_DUPLOCALE@
194 #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
195 #   undef duplocale
196 #   define duplocale rpl_duplocale
197 #  endif
198 _GL_FUNCDECL_RPL (duplocale, locale_t, (locale_t locale) _GL_ARG_NONNULL ((1)));
199 _GL_CXXALIAS_RPL (duplocale, locale_t, (locale_t locale));
200 # else
201 #  if @HAVE_DUPLOCALE@
202 _GL_CXXALIAS_SYS (duplocale, locale_t, (locale_t locale));
203 #  endif
204 # endif
205 # if @HAVE_DUPLOCALE@
206 _GL_CXXALIASWARN (duplocale);
207 # endif
208 #elif defined GNULIB_POSIXCHECK
209 # undef duplocale
210 # if HAVE_RAW_DECL_DUPLOCALE
211 _GL_WARN_ON_USE (duplocale, "duplocale is buggy on some glibc systems - "
212                  "use gnulib module duplocale for portability");
213 # endif
214 #endif
215
216 #endif /* _@GUARD_PREFIX@_LOCALE_H */
217 #endif /* ! _GL_ALREADY_INCLUDING_LOCALE_H */
218 #endif /* _@GUARD_PREFIX@_LOCALE_H */