Skip to content

Commit 1524c05

Browse files
committed
amend after cherry-pick from core-tcl (dataPtr vs. clientData); regenerate tclDate.c by yacc (bison)
1 parent 372dabf commit 1524c05

2 files changed

Lines changed: 11 additions & 10 deletions

File tree

generic/tclClock.c

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4261,12 +4261,13 @@ ClockCalcRelTime(
42614261

42624262
/* If relative time is there, adjust it in UTC as mentioned above. */
42634263
if (yyRelSeconds) {
4264+
ClockClientData *dataPtr = opts->clientData;
42644265
/*
42654266
* If timezone is not GMT/UTC (due to DST-hole, local time offset),
42664267
* we shall do in-between conversion to UTC to append seconds there
42674268
* and hereafter convert back to TZ, otherwise apply it direct here.
42684269
*/
4269-
if (opts->timezoneObj != opts->dataPtr->literals[LIT_GMT]) {
4270+
if (opts->timezoneObj != dataPtr->literals[LIT_GMT]) {
42704271
/*
42714272
* Convert date info structure into UTC seconds and add relative
42724273
* seconds (happens in commit).
@@ -4276,7 +4277,7 @@ ClockCalcRelTime(
42764277
}
42774278
yyRelSeconds = 0;
42784279
/* Convert it back */
4279-
if (ClockGetDateFields(opts->dataPtr, opts->interp, &yydate,
4280+
if (ClockGetDateFields(dataPtr, opts->interp, &yydate,
42804281
opts->timezoneObj, GREGORIAN_CHANGE_DATE) != TCL_OK) {
42814282
/* TODO - GREGORIAN_CHANGE_DATE should be locale-dependent */
42824283
return TCL_ERROR;

generic/tclDate.c

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -716,14 +716,14 @@ static const yytype_int8 yytranslate[] =
716716
/* YYRLINE[YYN] -- Source line where rule number YYN was defined. */
717717
static const yytype_int16 yyrline[] =
718718
{
719-
0, 171, 171, 172, 176, 179, 182, 185, 188, 191,
720-
194, 197, 201, 204, 209, 215, 221, 226, 230, 234,
721-
238, 242, 246, 252, 253, 256, 260, 264, 268, 272,
722-
276, 282, 288, 292, 297, 298, 303, 307, 312, 316,
723-
321, 328, 332, 338, 338, 340, 345, 350, 352, 357,
724-
359, 360, 368, 379, 393, 398, 401, 404, 407, 410,
725-
413, 416, 421, 424, 429, 433, 437, 443, 446, 449,
726-
454, 472, 475
719+
0, 171, 171, 172, 176, 179, 182, 185, 189, 193,
720+
196, 199, 203, 206, 211, 217, 223, 228, 232, 236,
721+
240, 244, 248, 254, 255, 258, 262, 266, 270, 274,
722+
278, 284, 290, 294, 299, 300, 305, 309, 314, 318,
723+
323, 330, 334, 340, 340, 342, 347, 352, 354, 359,
724+
361, 362, 370, 381, 396, 401, 404, 407, 410, 413,
725+
416, 419, 424, 427, 432, 437, 442, 449, 452, 455,
726+
460, 478, 481
727727
};
728728
#endif
729729

0 commit comments

Comments
 (0)