summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--ChangeLog8
-rw-r--r--library/clock.tcl24
-rw-r--r--unix/Makefile.in6
3 files changed, 23 insertions, 15 deletions
diff --git a/ChangeLog b/ChangeLog
index fef4b86..6a6a274 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+2005-12-02 Kevin B. Kenny <kennykb@acm.org>
+
+ * library/clock.tcl: Moved a tiny bit more of [clock format] from
+ run time to compile time, and fixed a l10n bug in the process.
+ [Bug 1371446]
+ * unix/Makefile.in: Made some changes to support a 'make' command
+ that is present on some antiquated versions of Solaris.
+
2005-12-01 Kevin B. Kenny <kennykb@acm.org>
* library/clock.tcl: Continued rationalizing the code, eliminating
diff --git a/library/clock.tcl b/library/clock.tcl
index c24a589..0c8bdaa 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.25 2005/12/01 22:38:05 kennykb Exp $
+# RCS: @(#) $Id: clock.tcl,v 1.26 2005/12/02 16:58:13 kennykb Exp $
#
#----------------------------------------------------------------------
@@ -652,8 +652,6 @@ proc ::tcl::clock::Initialize {} {
proc ::tcl::clock::format { args } {
- variable TZData
-
set format {}
# Check the count of args
@@ -731,16 +729,10 @@ proc ::tcl::clock::format { args } {
return -options $opts $retval
}
- # Extract the fields of the date.
-
- set date [GetDateFields $clockval \
- $TZData($timezone) \
- [mc GREGORIAN_CHANGE_DATE]]
-
# Format the result
set formatter [ParseClockFormatFormat $format $locale]
- return [$formatter $date $TZData($timezone)]
+ return [$formatter $clockval $timezone]
}
@@ -802,7 +794,15 @@ proc ::tcl::clock::ParseClockFormatFormat2 {format locale procName} {
set didLocaleEra 0
set didLocaleNumerals 0
- set preFormatCode {}
+ set preFormatCode \
+ [string map [list @GREGORIAN_CHANGE_DATE@ \
+ [mc GREGORIAN_CHANGE_DATE]] \
+ {
+ variable TZData
+ set date [GetDateFields $clockval \
+ $TZData($timezone) \
+ @GREGORIAN_CHANGE_DATE@]
+ }]
set formatString {}
set substituents {}
set state {}
@@ -1207,7 +1207,7 @@ proc ::tcl::clock::ParseClockFormatFormat2 {format locale procName} {
}
}
- proc $procName {date changeover} "
+ proc $procName {clockval timezone} "
$preFormatCode
return \[::format [list $formatString] $substituents\]
"
diff --git a/unix/Makefile.in b/unix/Makefile.in
index 23051c2..e84e109 100644
--- a/unix/Makefile.in
+++ b/unix/Makefile.in
@@ -5,7 +5,7 @@
# "autoconf" program (constructs like "@foo@" will get replaced in the
# actual Makefile.
#
-# RCS: @(#) $Id: Makefile.in,v 1.180 2005/12/01 11:05:02 dkf Exp $
+# RCS: @(#) $Id: Makefile.in,v 1.181 2005/12/02 16:58:14 kennykb Exp $
VERSION = @TCL_VERSION@
MAJOR_VERSION = @TCL_MAJOR_VERSION@
@@ -281,8 +281,8 @@ ${NO_DEPRECATED_FLAGS} ${ENV_FLAGS} @EXTRA_CC_SWITCHES@
STUB_CC_SWITCHES = ${CFLAGS} ${CFLAGS_WARNING} ${SHLIB_CFLAGS} \
-I${BUILD_DIR} -I${UNIX_DIR} -I${GENERIC_DIR} -DTCL_TOMMATH -DMP_PREC=4 \
--I${TOMMATH_DIR} ${AC_FLAGS} ${GENERIC_FLAGS} ${PROTO_FLAGS} ${ENV_FLAGS} \
-@EXTRA_CC_SWITCHES@
+-I${TOMMATH_DIR} ${AC_FLAGS} ${GENERIC_FLAGS} ${PROTO_FLAGS} \
+${ENV_FLAGS} @EXTRA_CC_SWITCHES@
LIBS = @TCL_LIBS@