Commit Graph

15 Commits

Author SHA1 Message Date
David Chisnall
3c87aa1d3d Implement xlocale APIs from Darwin, mainly for use by libc++. This adds a
load of _l suffixed versions of various standard library functions that use
the global locale, making them take an explicit locale parameter.  Also
adds support for per-thread locales.  This work was funded by the FreeBSD
Foundation.

Please test any code you have that uses the C standard locale functions!

Reviewed by:    das (gdtoa changes)
Approved by:    dim (mentor)
2011-11-20 14:45:42 +00:00
Alexey Zelkin
2992b5e82c Remove 3rd clause of license
Per request of: glenn halperin at symbian.com
2007-12-12 07:43:23 +00:00
Alexey Zelkin
683fe11379 . style(9)
. fix/add comments (to cover changes done thru last 20 months)
. extend monetary testcase to cover int_* values
2003-06-26 10:46:16 +00:00
Tim J. Robbins
f4da1a754d Add support for the 6 new C99 struct lconv members dealing with formatting
international monetary values: int_p_cs_precedes, int_n_cs_precedes,
int_p_sep_by_space, int_n_sep_by_space, int_p_sign_posn, int_n_sign_posn.
This should not break existing binaries or LC_MONETARY data files.

Reviewed by:	ache
MFC after:	1 month
2002-10-09 09:19:28 +00:00
David E. O'Brien
333fc21e3c Fix the style of the SCM ID's.
I believe have made all of libc .c's as consistent as possible.
2002-03-22 21:53:29 +00:00
Andrey A. Chernov
831e8f614c Do not try to convert to char already converted C monetary locale members.
Do this conversion on locale load stage instead.
2002-01-28 08:26:38 +00:00
Alexey Zelkin
f2d0f4274b Add my e-mail to copyrights 2001-12-20 15:30:02 +00:00
David E. O'Brien
1e58303f9f Use our standard .c rcsid format. 2001-03-05 10:21:05 +00:00
David E. O'Brien
e4efb830ff Fix copyright breakage in rev 1.2.
We *cannot* remove clause #4 from the Univ of California's license.
2001-03-05 10:18:15 +00:00
Alexey Zelkin
1bd7723d09 . Fix semantics of grouping (LC_MONETARY::mon_grouping,
LC_NUMERIC::grouping) values.
. Always set __XXX_changed flags then loading numeric & monetary locale
  categories to allow localeconv() to use C locale also.
2001-02-10 15:36:46 +00:00
Andrey A. Chernov
ab9577f234 As temporary workaround for missing *grouping fields parser always return "no
grouping" (CHAR_MAX, '\0').
Fixme: grouping parser needs to be implemented.
2001-02-10 04:32:55 +00:00
Andrey A. Chernov
96be743f80 According to Garrett, POSIX widely use -1 to indicate CHAR_MAX, so back out
all my "-1" -> "something" fixes and replace -1 with CHAR_MAX directly in
strtol() in cnv()
2001-02-10 03:31:23 +00:00
Andrey A. Chernov
d2712eafa7 Use __XSTRING(CHAR_MAX) instead of "127" and strtol() base 0 to parse it (0x7f) 2001-02-10 02:00:56 +00:00
Alexey Zelkin
e690a5563f Make localeconv() actual function. Now it will use LC_MONETARY/LC_NUMERIC
information to fill return structure. Remove unused anymore stub.
2001-02-08 17:03:01 +00:00
Rodney W. Grimes
58f0484fa2 BSD 4.4 Lite Lib Sources 1994-05-27 05:00:24 +00:00