This is the mail archive of the glibc-cvs@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

GNU C Library master sources branch master updated. glibc-2.18-408-gb5449b1


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU C Library master sources".

The branch, master has been updated
       via  b5449b12962da665c29f0a1c85f705de4bc4abf2 (commit)
      from  e186536b6fa8ceb004dfa1ba45766edcc871a95b (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=b5449b12962da665c29f0a1c85f705de4bc4abf2

commit b5449b12962da665c29f0a1c85f705de4bc4abf2
Author: Andreas Schwab <schwab@suse.de>
Date:   Mon Nov 11 18:12:03 2013 +0100

    Complete display of LC_MONETARY

diff --git a/ChangeLog b/ChangeLog
index b0ca6f7..9568016 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,12 @@
+2013-11-19  Andreas Schwab  <schwab@suse.de>
+
+	* locale/programs/locale.c (show_info): Decode wordarray elements.
+	* locale/categories.def (LC_MONETARY): Add element for
+	_NL_MONETARY_CRNCYSTR.
+	* locale/C-monetary.c (conversion_rate): New variable.
+	(_nl_C_LC_MONETARY): Use it for _NL_MONETARY_CONVERSION_RATE
+	element.
+
 2013-11-18  Chris Metcalf  <cmetcalf@tilera.com>
 
 	* math/test-fpucw-ieee.c [!defined _FPU_IEEE] (FPU_CONTROL):
diff --git a/locale/C-monetary.c b/locale/C-monetary.c
index 3246ff5..9c36c76 100644
--- a/locale/C-monetary.c
+++ b/locale/C-monetary.c
@@ -22,6 +22,7 @@
    ``LC_MONETARY Category Definition in the POSIX Locale'',
    with additions from ISO 14652, section 4.4.  */
 static const char not_available[] = "\377";
+static const uint32_t conversion_rate[] = { 1, 1 };
 
 const struct __locale_data _nl_C_LC_MONETARY attribute_hidden =
 {
@@ -74,7 +75,7 @@ const struct __locale_data _nl_C_LC_MONETARY attribute_hidden =
     { .word = 99991231 },
     { .word = 10101 },
     { .word = 99991231 },
-    { .word = 1 },
+    { .string = (const char *) conversion_rate },
     { .word = (unsigned int) L'\0' },
     { .word = (unsigned int) L'\0' },
     { .string = _nl_C_codeset }
diff --git a/locale/categories.def b/locale/categories.def
index 8c25378..e1172e9 100644
--- a/locale/categories.def
+++ b/locale/categories.def
@@ -156,6 +156,7 @@ DEFINE_CATEGORY
   DEFINE_ELEMENT (N_SEP_BY_SPACE,                      "n_sep_by_space",         std, byte, 0, 2)
   DEFINE_ELEMENT (P_SIGN_POSN,                         "p_sign_posn",            std, byte, 0, 4)
   DEFINE_ELEMENT (N_SIGN_POSN,                         "n_sign_posn",            std, byte, 0, 4)
+  DEFINE_ELEMENT (_NL_MONETARY_CRNCYSTR,               "crncystr",               std, string)
   DEFINE_ELEMENT (__INT_P_CS_PRECEDES,                 "int_p_cs_precedes",      std, byte, 0, 1)
   DEFINE_ELEMENT (__INT_P_SEP_BY_SPACE,                "int_p_sep_by_space",     std, byte, 0, 2)
   DEFINE_ELEMENT (__INT_N_CS_PRECEDES,                 "int_n_cs_precedes",      std, byte, 0, 1)
diff --git a/locale/programs/locale.c b/locale/programs/locale.c
index c0bdb6c..d2b28d0 100644
--- a/locale/programs/locale.c
+++ b/locale/programs/locale.c
@@ -927,6 +927,24 @@ show_info (const char *name)
 	    printf ("%d\n", val.word);
 	  }
 	  break;
+	case wordarray:
+	  {
+	    int first = 1;
+	    union { unsigned int *wordarray; char *string; } val;
+	    int cnt;
+
+	    val.string = nl_langinfo (item->item_id);
+	    if (show_keyword_name)
+	      printf ("%s=", item->name);
+
+	    for (cnt = 0; cnt < item->max; ++cnt)
+	      {
+		printf ("%s%d", first ? "" : ";", val.wordarray[cnt]);
+		first = 0;
+	      }
+	    putchar ('\n');
+	  }
+	  break;
 	case wstring:
 	case wstringarray:
 	case wstringlist:

-----------------------------------------------------------------------

Summary of changes:
 ChangeLog                |    9 +++++++++
 locale/C-monetary.c      |    3 ++-
 locale/categories.def    |    1 +
 locale/programs/locale.c |   18 ++++++++++++++++++
 4 files changed, 30 insertions(+), 1 deletions(-)


hooks/post-receive
-- 
GNU C Library master sources


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]