This is the mail archive of the libc-alpha@sources.redhat.com 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]

[PATCH] adding i18n digits to fa_IR


Hi,

'I' flag has been implemented in scanf for about 4 years. The only way
that we can use this feature is to add a set of extended digits to digit
tag which is useless since ISO C has forbidden us. Though it was
implemented in localedef to accept multiple of 10 (and not just 10)
digits in digit tag (see /locale/programs/ld-ctype.c line 708).

Please clarify this. If it's possible apply this small patch for fa_IR.
It adds two Arabic and Persian digits sets to digit tag and remove them
from alpha tag in i18n file. It solve all we need. If not, Do you accept
a patch for vfscanf.c that replace implemented code with something which
reads its data from a map in locale file?

Hamed


diff -ru localedata/locales.orig/fa_IR localedata/locales/fa_IR
--- localedata/locales.orig/fa_IR	2004-06-29 18:05:07.781363848 +0430
+++ localedata/locales/fa_IR	2004-06-29 18:01:47.020884080 +0430
@@ -47,6 +47,9 @@
 
 LC_CTYPE
 copy "i18n"
+digit  <U0030>..<U0039>; /
+       <U06F0>..<U06F9>; /
+       <U0660>..<U0669>
 
 outdigit <U06F0>..<U06F9>
 
diff -ru localedata/locales.orig/i18n localedata/locales/i18n
--- localedata/locales.orig/i18n	2004-06-29 18:05:07.593392424 +0430
+++ localedata/locales/i18n	2004-06-29 18:03:28.862401816 +0430
@@ -351,8 +351,6 @@
 % The non-ASCII number characters are included here because ISO C 99    /
 % forbids us to classify them as digits; however, they behave more like /
 % alphanumeric than like punctuation.                                   /
-% TABLE 15 and 16 ARABIC/
-   <U0660>..<U0669>;<U06F0>..<U06F9>;/
 % TABLE 17 DEVANAGARI/
    <U0966>..<U096F>;/
 % TABLE 18 BENGALI/

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