bug-gnu-utils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: thousands separator


From: Eli Zaretskii
Subject: Re: thousands separator
Date: Fri, 03 Jul 2009 16:12:17 +0300

> Date: Fri, 03 Jul 2009 06:36:37 -0400
> From: Gary Ashburn <address@hidden>
> Cc: address@hidden
> 
> much more simple test - good idea
> 
> result is still random character:
> 
> 
> C:\C\UTIL>echo BEGIN { printf("%'d\n", 123456789 ) } > awktest.awk
> 
> C:\C\UTIL>awk -f awktest.awk
> 123V456V789
> 
> C:\C\UTIL>awk -f awktest.awk
> 123Ö456Ö789

I cannot reproduce this on XPSP2, with Gawk 3.1.6.  I get 123456789
every time.  I get the same on this GNU/Linux machine:

  Linux fencepost 2.6.16.29-xen #1 SMP Wed Dec 6 07:32:36 EST 2006 x86_64 
GNU/Linux

Where did you get your Gawk binary?  Mine was compiled from sources
with the MinGW port of GCC.

Also, what is your Windows locale?  You can see that if you click
Start->Control Panel->Regional and Language Options, on the "Regional
Options" tab.  (The names are probably different on Vista.)  Please
also tell what language is selected for non-Unicode (a.k.a. ANSI)
programs.  On XP, this is in the Advanced tab of the same applet as
described above.

> >This is undoubtedly some kind of locale issue; Windows systems have
> >limited or nonexistent support for these kinds of things.

No locale should produce random results.  And Windows systems do
support the locale related features, certainly the thousands
separator.

> >If you set LC_ALL=C in the environment, that might help, but in this case
> >you won't get a thousands separator at all.

Windows run-time libraries generally do not honor LC_ALL.  Unless we
are talking about a Cygwin port of Gawk.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]