summaryrefslogtreecommitdiffstats
path: root/generic/tclDate.c
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2018-11-15 08:19:24 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2018-11-15 08:19:24 (GMT)
commit9214af654398982e16186d0ae70f37b3580f0295 (patch)
tree131e8376cbc6f60ee9617b3ba92204a08ae41e29 /generic/tclDate.c
parenta69045247e1387fc673deb432549cb266e5009ee (diff)
parent65ae2c205ec2dfe95ce012b45d5d3adc07370685 (diff)
downloadtcl-9214af654398982e16186d0ae70f37b3580f0295.zip
tcl-9214af654398982e16186d0ae70f37b3580f0295.tar.gz
tcl-9214af654398982e16186d0ae70f37b3580f0295.tar.bz2
Merge 8.7
Fix Tcl_InitStringRep() signature in line with TIP #494, so it can handle lengths >2Gb on 64-bit platforms Various other code cleanups, unnecessary type-casts e.o.
Diffstat (limited to 'generic/tclDate.c')
-rw-r--r--generic/tclDate.c24
1 files changed, 12 insertions, 12 deletions
diff --git a/generic/tclDate.c b/generic/tclDate.c
index 0aadc82..5a4ddd5 100644
--- a/generic/tclDate.c
+++ b/generic/tclDate.c
@@ -2848,16 +2848,16 @@ TclClockOldscanObjCmd(
resultElement = Tcl_NewObj();
if (yyHaveDate) {
Tcl_ListObjAppendElement(interp, resultElement,
- Tcl_NewIntObj((int) yyYear));
+ Tcl_NewIntObj(yyYear));
Tcl_ListObjAppendElement(interp, resultElement,
- Tcl_NewIntObj((int) yyMonth));
+ Tcl_NewIntObj(yyMonth));
Tcl_ListObjAppendElement(interp, resultElement,
- Tcl_NewIntObj((int) yyDay));
+ Tcl_NewIntObj(yyDay));
}
Tcl_ListObjAppendElement(interp, result, resultElement);
if (yyHaveTime) {
- Tcl_ListObjAppendElement(interp, result, Tcl_NewIntObj((int)
+ Tcl_ListObjAppendElement(interp, result, Tcl_NewIntObj(
ToSeconds(yyHour, yyMinutes, yySeconds, yyMeridian)));
} else {
Tcl_ListObjAppendElement(interp, result, Tcl_NewObj());
@@ -2866,7 +2866,7 @@ TclClockOldscanObjCmd(
resultElement = Tcl_NewObj();
if (yyHaveZone) {
Tcl_ListObjAppendElement(interp, resultElement,
- Tcl_NewIntObj((int) -yyTimezone));
+ Tcl_NewIntObj(-yyTimezone));
Tcl_ListObjAppendElement(interp, resultElement,
Tcl_NewIntObj(1 - yyDSTmode));
}
@@ -2875,29 +2875,29 @@ TclClockOldscanObjCmd(
resultElement = Tcl_NewObj();
if (yyHaveRel) {
Tcl_ListObjAppendElement(interp, resultElement,
- Tcl_NewIntObj((int) yyRelMonth));
+ Tcl_NewIntObj(yyRelMonth));
Tcl_ListObjAppendElement(interp, resultElement,
- Tcl_NewIntObj((int) yyRelDay));
+ Tcl_NewIntObj(yyRelDay));
Tcl_ListObjAppendElement(interp, resultElement,
- Tcl_NewIntObj((int) yyRelSeconds));
+ Tcl_NewIntObj(yyRelSeconds));
}
Tcl_ListObjAppendElement(interp, result, resultElement);
resultElement = Tcl_NewObj();
if (yyHaveDay && !yyHaveDate) {
Tcl_ListObjAppendElement(interp, resultElement,
- Tcl_NewIntObj((int) yyDayOrdinal));
+ Tcl_NewIntObj(yyDayOrdinal));
Tcl_ListObjAppendElement(interp, resultElement,
- Tcl_NewIntObj((int) yyDayNumber));
+ Tcl_NewIntObj(yyDayNumber));
}
Tcl_ListObjAppendElement(interp, result, resultElement);
resultElement = Tcl_NewObj();
if (yyHaveOrdinalMonth) {
Tcl_ListObjAppendElement(interp, resultElement,
- Tcl_NewIntObj((int) yyMonthOrdinal));
+ Tcl_NewIntObj(yyMonthOrdinal));
Tcl_ListObjAppendElement(interp, resultElement,
- Tcl_NewIntObj((int) yyMonth));
+ Tcl_NewIntObj(yyMonth));
}
Tcl_ListObjAppendElement(interp, result, resultElement);