Hi Jürgen,
I see. Perhaps controlling this programmatically, as I believe you
described, does make more sense.
Thanks!
Blake
On Wed, Jul 6, 2022 at 11:29 AM Dr. Jürgen Sauermann <
mail@jürgen-sauermann.de> wrote:
> Hi Blake,
>
> in theory: yes. The problem is that the behaviour of locales ca
Hi Blake,
in theory: yes. The problem is that the behaviour of locales can be quite
unpredictable and therefore allowing to change it means that the underlying
glibc may produce results that are no easy to foresee. The current problem
(the thousands' separator) is a good example for this.
For mo
On Wed, Jul 6, 2022 at 7:07 AM Dr. Jürgen Sauermann <
mail@jürgen-sauermann.de> wrote:
> [...]
> The problem is, though, that calling setlocale()
> in GNU APL is problematic since I cannot possibly know beforehand
> what the locale of the user will be.
>
Can't this be set in ~/.gnu-apl/preference
Hi Christian,
thanks for the info. The problem is, though, that calling
setlocale()
in GNU APL is problematic since I cannot possibly know beforehand
what the locale of the user will be. And I cannot know all
peculiarities
of all possible locale
Jürgen,
#include
#include
int
main(int argc, char *argv[])
{
setlocale (LC_NUMERIC, "en_US.utf8");
printf("%'f\n", 55.66);
}
print:
555,555.66
my 2 cents...
Xtian.
On 2022-07-05 12:40, Dr. Jürgen Sauermann wrote:
Hi Martin,
I believe I understood your problem now. As fa
Hi Jürgen,
> I believe I understood your problem now. As far as ⎕FIO is concerned it
> should be fixed
> in SVN 1579:
Many thanks, it's very impressive how fast you have implemented this
change!
> There could be a misunderstanding as to how 'Format by example' works (and
> that misunderstandi
Hi Martin,
I believe I understood your problem now. As far as ⎕FIO is
concerned it should be fixed
in SVN 1579:
"%'.2f" ⎕FIO.sprintf 1234567.89
1,234,567.89
There could be a misunderstanding as to how 'Format by ex
Hi Jürgen,
thanks for your quick reply.
> I will look into adding support for the thousands separator (but not
> supporting the
> locales nonsense). That is, the thousands separator will always be comma and
> not
> e.g. full-stop like in some countries and comma in others.
That would be great
Hi Martin,
actually ⎕FIO emulates printf() rather than calling it. There were
a number of
nasty effects caused by locales when using printf() and friends
and therefore I
decided to implement it explicitly. For that reason not all format
flags ar
Hi there,
I want to print a table which also includes some financal figures. Here
I need to group with a thousands separator. My first attempts using the
"Format by example" method failed due to limitations of it. That's why I
fell back to the ⎕FIO system interface, trying the same with `printf`.
10 matches
Mail list logo