forked from wuzhouhui/c_standard_lib
-
Notifications
You must be signed in to change notification settings - Fork 0
/
LOCALE.H
47 lines (47 loc) · 1.05 KB
/
LOCALE.H
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
/* locale.h standard header */
#ifndef _LOCALE
#define _LOCALE
#ifndef _YVALS
#include <yvals.h>
#endif
/* macros */
#define NULL _NULL
/* locale codes */
#define LC_ALL 0
#define LC_COLLATE 1
#define LC_CTYPE 2
#define LC_MONETARY 3
#define LC_NUMERIC 4
#define LC_TIME 5
/* ADD YOURS HERE */
#define _NCAT 6 /* one more than last */
/* type definitions */
struct lconv {
/* controlled by LC_MONETARY */
char *currency_symbol;
char *int_curr_symbol;
char *mon_decimal_point;
char *mon_grouping;
char *mon_thousands_sep;
char *negative_sign;
char *positive_sign;
char frac_digits;
char int_frac_digits;
char n_cs_precedes;
char n_sep_by_space;
char n_sign_posn;
char p_cs_precedes;
char p_sep_by_space;
char p_sign_posn;
/* controlled by LC_NUMERIC */
char *decimal_point;
char *grouping;
char *thousands_sep;
};
/* declarations */
struct lconv *localeconv(void);
char *setlocale(int, const char *);
extern struct lconv _Locale;
/* macro overrides */
#define localeconv() (&_Locale)
#endif