guile-devel
[Top][All Lists]
Advanced

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

Re: Accessing the environment's locale encoding settings


From: Mike Gran
Subject: Re: Accessing the environment's locale encoding settings
Date: Wed, 23 Nov 2011 20:42:11 -0800 (PST)

> From: Ludovic Courtès <address@hidden>

>>  Here's a suggestion.  One could add an option to the guile 
> interpreter's command
>>  line args (--locale=ARG perhaps) that has the effect of calling
>>  setlocale(LC_ALL,"ARG") first thing.  If --locale is called 
> with no ARG
>>  specified, it would call to setlocale(LC_ALL, "").
> 
> I tried something along these lines:

Looks good to me, but, I didn't much chance to test it.

A basic check would be if

   guile --locale -c "(write 'キ)" | wc

outputs 3 characters or 1.

One big check would be if we can run a script with a non-ASCII
file name -- which would be in the system's locale encoding.

That script could contain code, and a "coding:" declaration, in
a different non-ASCII encoding, just to make it fun.

-Mike




reply via email to

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