summaryrefslogtreecommitdiffstats
path: root/library/clock.tcl
diff options
context:
space:
mode:
authorKevin B Kenny <kennykb@acm.org>2007-04-15 18:59:31 (GMT)
committerKevin B Kenny <kennykb@acm.org>2007-04-15 18:59:31 (GMT)
commit9884845dfb273bf59b75b1d7f58b2de7afaf5863 (patch)
treeb0946b34be7ab6aa2fea8e8fc070c3436222dd9d /library/clock.tcl
parent5a6b65068cccb6e5109ddd85bd447bffbbf2f335 (diff)
downloadtcl-9884845dfb273bf59b75b1d7f58b2de7afaf5863.zip
tcl-9884845dfb273bf59b75b1d7f58b2de7afaf5863.tar.gz
tcl-9884845dfb273bf59b75b1d7f58b2de7afaf5863.tar.bz2
* generic/tclCompCmds.c: added a cast to silence a compiler
error on VC2005. * library/clock.tcl: Restored unique-prefix matching of keywords on the [clock] command. [Bug 1690041] * tests/clock.test: Added rudimentary test cases for unique-prefix matching of keywords.
Diffstat (limited to 'library/clock.tcl')
-rw-r--r--library/clock.tcl25
1 files changed, 13 insertions, 12 deletions
diff --git a/library/clock.tcl b/library/clock.tcl
index da4309c..d678a7c 100644
--- a/library/clock.tcl
+++ b/library/clock.tcl
@@ -13,7 +13,7 @@
# See the file "license.terms" for information on usage and redistribution
# of this file, and for a DISCLAIMER OF ALL WARRANTIES.
#
-# RCS: @(#) $Id: clock.tcl,v 1.40 2007/03/09 01:09:00 kennykb Exp $
+# RCS: @(#) $Id: clock.tcl,v 1.41 2007/04/15 18:59:34 kennykb Exp $
#
#----------------------------------------------------------------------
@@ -689,16 +689,16 @@ proc ::tcl::clock::format { args } {
foreach { flag value } [lreplace $args 0 0] {
set saw($flag) {}
switch -exact -- $flag {
- -format {
+ -f - -fo - -for - -form - -forma - -format {
set format $value
}
- -gmt {
+ -g - -gm - -gmt {
set gmt $value
}
- -locale {
+ -l - -lo - -loc - -loca - -local - -locale {
set locale $value
}
- -timezone {
+ -t - -ti - -tim - -time - -timez - -timezo - -timezon - -timezone {
set timezone $value
}
default {
@@ -1282,19 +1282,19 @@ proc ::tcl::clock::scan { args } {
foreach { flag value } [lreplace $args 0 0] {
set saw($flag) {}
switch -exact -- $flag {
- -base {
+ -b - -ba - -bas - -base {
set base $value
}
- -format {
+ -f - -fo - -for - -form - -forma - -format {
set format $value
}
- -gmt {
+ -g - -gm - -gmt {
set gmt $value
}
- -locale {
+ -l - -lo - -loc - -loca - -local - -locale {
set locale $value
}
- -timezone {
+ -t - -ti - -tim - -time - -timez - -timezo - -timezon - -timezone {
set timezone $value
}
default {
@@ -4404,12 +4404,13 @@ proc ::tcl::clock::add { clockval args } {
switch -exact -- $a {
- -gmt {
+ -g - -gm - -gmt {
set gmt $b
}
- -locale {
+ -l - -lo - -loc - -loca - -local - -locale {
set locale $b
}
+ -t - -ti - -tim - -time - -timez - -timezo - -timezon -
-timezone {
set timezone $b
}