summaryrefslogtreecommitdiffstats
path: root/generic/tclArithSeries.c
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2022-09-28 13:17:31 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2022-09-28 13:17:31 (GMT)
commit487067a6d17bc8a87213c22d6c20ffd95d27b208 (patch)
tree3698c85b7e21dbff2984820697c18d3f92d11f26 /generic/tclArithSeries.c
parent0a9f0f35987e8e20af40f82d42248912dbf58013 (diff)
parent93e50d1448aba1ed4b5eb113ea5c9b5debee85dc (diff)
downloadtcl-487067a6d17bc8a87213c22d6c20ffd95d27b208.zip
tcl-487067a6d17bc8a87213c22d6c20ffd95d27b208.tar.gz
tcl-487067a6d17bc8a87213c22d6c20ffd95d27b208.tar.bz2
Merge 8.7
Diffstat (limited to 'generic/tclArithSeries.c')
-rwxr-xr-xgeneric/tclArithSeries.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/generic/tclArithSeries.c b/generic/tclArithSeries.c
index f2e044c..1346514 100755
--- a/generic/tclArithSeries.c
+++ b/generic/tclArithSeries.c
@@ -106,8 +106,10 @@ ArithSeriesLen(Tcl_WideInt start, Tcl_WideInt end, Tcl_WideInt step)
{
Tcl_WideInt len;
- if (step == 0) return 0;
- len = (step ? (1 + (((end-start))/step)) : 0);
+ if (step == 0) {
+ return 0;
+ }
+ len = 1 + ((end-start)/step);
return (len < 0) ? -1 : len;
}
@@ -233,7 +235,7 @@ assignNumber(int useDoubles, Tcl_WideInt *intNumberPtr, double *dblNumberPtr, Tc
} *number;
int tcl_number_type;
- if (Tcl_GetNumberFromObj(NULL, numberObj, (ClientData*)&number, &tcl_number_type) != TCL_OK) {
+ if (Tcl_GetNumberFromObj(NULL, numberObj, (void **)&number, &tcl_number_type) != TCL_OK) {
return;
}
if (useDoubles) {
@@ -818,7 +820,7 @@ TclArithSeriesGetElements(
Tcl_Interp *interp, /* Used to report errors if not NULL. */
Tcl_Obj *objPtr, /* AbstractList object for which an element
* array is to be returned. */
- int *objcPtr, /* Where to store the count of objects
+ ListSizeT *objcPtr, /* Where to store the count of objects
* referenced by objv. */
Tcl_Obj ***objvPtr) /* Where to store the pointer to an array of
* pointers to the list's objects. */