diff options
| -rw-r--r-- | generic/tclBasic.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/generic/tclBasic.c b/generic/tclBasic.c index 81e1927..93776dc 100644 --- a/generic/tclBasic.c +++ b/generic/tclBasic.c @@ -7638,7 +7638,7 @@ ExprEntierFunc( if (type == TCL_NUMBER_DOUBLE) { d = *((const double *) ptr); - if ((d >= (double)LONG_MAX) || (d <= (double)LONG_MIN)) { + if ((d >= (double)LLONG_MAX) || (d <= (double)LLONG_MIN)) { mp_int big; if (Tcl_InitBignumFromDouble(interp, d, &big) != TCL_OK) { @@ -7648,9 +7648,9 @@ ExprEntierFunc( Tcl_SetObjResult(interp, Tcl_NewBignumObj(&big)); return TCL_OK; } else { - long result = (long) d; + Tcl_WideInt result = (Tcl_WideInt) d; - Tcl_SetObjResult(interp, Tcl_NewLongObj(result)); + Tcl_SetObjResult(interp, Tcl_NewWideIntObj(result)); return TCL_OK; } } |
