diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2020-10-13 14:59:43 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2020-10-13 14:59:43 (GMT) |
commit | b074d0c649e79b372e9cb7a57a5b7bf96703f34d (patch) | |
tree | 5b6f3de70fca08f3638540445bd5f25b522f87b6 /generic/tclGetDate.y | |
parent | 72ddebeb2188c6cd0ba62b0e9b5eec82bc2f53f4 (diff) | |
download | tcl-b074d0c649e79b372e9cb7a57a5b7bf96703f34d.zip tcl-b074d0c649e79b372e9cb7a57a5b7bf96703f34d.tar.gz tcl-b074d0c649e79b372e9cb7a57a5b7bf96703f34d.tar.bz2 |
More usage of TclNewObj() in stead of Tcl_NewObj() and TclNewIntObj() in stead of Tcl_NewIntObj()
Diffstat (limited to 'generic/tclGetDate.y')
-rw-r--r-- | generic/tclGetDate.y | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/generic/tclGetDate.y b/generic/tclGetDate.y index 86037d6..65a3f86 100644 --- a/generic/tclGetDate.y +++ b/generic/tclGetDate.y @@ -716,12 +716,12 @@ TclDateerror( Tcl_AppendToObj(infoPtr->messages, infoPtr->separatrix, -1); Tcl_AppendToObj(infoPtr->messages, s, -1); Tcl_AppendToObj(infoPtr->messages, " (characters ", -1); - t = Tcl_NewIntObj(location->first_column); + TclNewIntObj(t, location->first_column); Tcl_IncrRefCount(t); Tcl_AppendObjToObj(infoPtr->messages, t); Tcl_DecrRefCount(t); Tcl_AppendToObj(infoPtr->messages, "-", -1); - t = Tcl_NewIntObj(location->last_column); + TclNewIntObj(t, location->last_column); Tcl_IncrRefCount(t); Tcl_AppendObjToObj(infoPtr->messages, t); Tcl_DecrRefCount(t); @@ -1003,7 +1003,7 @@ TclClockOldscanObjCmd( yyHaveRel = 0; yyRelMonth = 0; yyRelDay = 0; yyRelSeconds = 0; yyRelPointer = NULL; - dateInfo.messages = Tcl_NewObj(); + TclNewObj(dateInfo.messages); dateInfo.separatrix = ""; Tcl_IncrRefCount(dateInfo.messages); @@ -1060,8 +1060,8 @@ TclClockOldscanObjCmd( return TCL_ERROR; } - result = Tcl_NewObj(); - resultElement = Tcl_NewObj(); + TclNewObj(result); + TclNewObj(resultElement); if (yyHaveDate) { Tcl_ListObjAppendElement(interp, resultElement, Tcl_NewIntObj((int) yyYear)); @@ -1079,7 +1079,7 @@ TclClockOldscanObjCmd( Tcl_ListObjAppendElement(interp, result, Tcl_NewObj()); } - resultElement = Tcl_NewObj(); + TclNewObj(resultElement); if (yyHaveZone) { Tcl_ListObjAppendElement(interp, resultElement, Tcl_NewIntObj((int) -yyTimezone)); @@ -1088,7 +1088,7 @@ TclClockOldscanObjCmd( } Tcl_ListObjAppendElement(interp, result, resultElement); - resultElement = Tcl_NewObj(); + TclNewObj(resultElement); if (yyHaveRel) { Tcl_ListObjAppendElement(interp, resultElement, Tcl_NewIntObj((int) yyRelMonth)); @@ -1099,7 +1099,7 @@ TclClockOldscanObjCmd( } Tcl_ListObjAppendElement(interp, result, resultElement); - resultElement = Tcl_NewObj(); + TcNewObj(resultElement); if (yyHaveDay && !yyHaveDate) { Tcl_ListObjAppendElement(interp, resultElement, Tcl_NewIntObj((int) yyDayOrdinal)); @@ -1108,7 +1108,7 @@ TclClockOldscanObjCmd( } Tcl_ListObjAppendElement(interp, result, resultElement); - resultElement = Tcl_NewObj(); + TclNewObj(resultElement); if (yyHaveOrdinalMonth) { Tcl_ListObjAppendElement(interp, resultElement, Tcl_NewIntObj((int) yyMonthOrdinal)); |