summaryrefslogtreecommitdiffstats
path: root/generic/tclDate.h
diff options
context:
space:
mode:
authorsebres <sebres@users.sourceforge.net>2017-01-10 22:21:26 (GMT)
committersebres <sebres@users.sourceforge.net>2017-01-10 22:21:26 (GMT)
commitdc9796c6e858828861b1339b4734bab19cccca4c (patch)
tree81cb2bbde61282f93461ce283eb461c4afef2e70 /generic/tclDate.h
parent18be594c8481eee9b98d140af50df7ccb3a3a79e (diff)
downloadtcl-dc9796c6e858828861b1339b4734bab19cccca4c.zip
tcl-dc9796c6e858828861b1339b4734bab19cccca4c.tar.gz
tcl-dc9796c6e858828861b1339b4734bab19cccca4c.tar.bz2
several initialize and finalize facilities
Diffstat (limited to 'generic/tclDate.h')
-rw-r--r--generic/tclDate.h14
1 files changed, 13 insertions, 1 deletions
diff --git a/generic/tclDate.h b/generic/tclDate.h
index 9585258..2010178 100644
--- a/generic/tclDate.h
+++ b/generic/tclDate.h
@@ -40,6 +40,9 @@
*/
typedef struct TclDateFields {
+
+ /* Cacheable fields: */
+
Tcl_WideInt seconds; /* Time expressed in seconds from the Posix
* epoch */
Tcl_WideInt localSeconds; /* Local time expressed in nominal seconds
@@ -60,6 +63,8 @@ typedef struct TclDateFields {
time_t minutes; /* Minutes of day (in-between time only calculation) */
time_t secondOfDay; /* Seconds of day (in-between time only calculation) */
+ /* Non cacheable fields: */
+
Tcl_Obj *tzName; /* Name (or corresponding DST-abbreviation) of the
* time zone, if set the refCount is incremented */
} TclDateFields;
@@ -74,10 +79,11 @@ typedef struct TclDateFields {
typedef struct DateInfo {
const char *dateStart;
const char *dateInput;
- int flags;
TclDateFields date;
+ int flags;
+
time_t dateHaveDate;
time_t dateMeridian;
@@ -138,6 +144,10 @@ typedef struct DateInfo {
#define yyInput (info->dateInput)
#define yyDigitCount (info->dateDigitCount)
+inline void
+ClockInitDateInfo(DateInfo *info) {
+ memset(info, 0, sizeof(DateInfo));
+}
/*
* Structure containing the command arguments supplied to [clock format] and [clock scan]
@@ -298,6 +308,8 @@ MODULE_SCOPE int ClockScan(ClientData clientData, Tcl_Interp *interp,
register DateInfo *info,
Tcl_Obj *strObj, ClockFmtScnCmdArgs *opts);
+MODULE_SCOPE void ClockFrmScnClearCaches(void);
+
/*
* Other externals.
*/