Skip to content
Tcl Source Code View Ticket
Login

View Ticket

clock scan does not work when locale is not English

Closed / Out of Date1028448fffffffffffffffffffffffffffffffffCreated 22 years agoUpdated 22 years ago
Descriptionplain2004-09-15 09:11:29
> ./tclsh
% clock format [clock scan [clock format [clock seconds]]]
Wed Sep 15 10:48:33 MEST 2004

> setenv LANG de_CH
> ./tclsh
% clock format [clock scan [clock format [clock seconds]]]
unable to convert date-time string "Mit Sep 15 10:48:47
MEST 2004"

> setenv LANG de_CH
> ./tclsh
% clock format [clock scan [clock format [clock seconds]]]
unable to convert date-time string "mer sep 15 11:06:14
MEST 2004"
rbrunnerplain2004-09-15 16:15:44
Logged In: YES 
user_id=205230

# sorry: the second setenv should have been:
> setenv LANG fr_FR
dgpplain2004-09-15 21:31:27
Logged In: YES 
user_id=80530


This is fixed in Tcl 8.5.
rbrunnerplain2004-09-15 21:48:35
Logged In: YES 
user_id=205230

Well, in my Tcl8.5a1 version, it isn't, but I don't know
about the HEAD ...

> setenv LANG de_CH
> ./tclsh 
% info patchlevel
8.5a1
% clock format [clock scan [clock format [clock seconds]]]
unable to convert date-time string "Mit Sep 15 16:46:54 MEST
2004"
%
dkfplain2004-09-16 14:56:58
Logged In: YES 
user_id=79902

It's post-8.5a1, but is in the HEAD. See
http://tip.tcl.tk/173 for details of the specification.
Log in (anonymous is fine) to add a comment.