summaryrefslogtreecommitdiffstats
path: root/compat/strtoull.c
diff options
context:
space:
mode:
authordkf <donal.k.fellows@manchester.ac.uk>2002-02-22 09:04:47 (GMT)
committerdkf <donal.k.fellows@manchester.ac.uk>2002-02-22 09:04:47 (GMT)
commitae707bf53694039c55ae485a246b5f037caaf2df (patch)
treeba6173acad2a1138f95ec9c9c72c0ccdea254d92 /compat/strtoull.c
parentc579847d1dcba72e52ba47a88a63cbe0cbd8dc7f (diff)
downloadtcl-ae707bf53694039c55ae485a246b5f037caaf2df.zip
tcl-ae707bf53694039c55ae485a246b5f037caaf2df.tar.gz
tcl-ae707bf53694039c55ae485a246b5f037caaf2df.tar.bz2
Const-ifying declarations of strtoll/strtoull and new compat code.
Diffstat (limited to 'compat/strtoull.c')
-rw-r--r--compat/strtoull.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/compat/strtoull.c b/compat/strtoull.c
index af508d0..9544d71 100644
--- a/compat/strtoull.c
+++ b/compat/strtoull.c
@@ -9,7 +9,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: strtoull.c,v 1.3 2002/02/15 23:42:12 kennykb Exp $
+ * RCS: @(#) $Id: strtoull.c,v 1.4 2002/02/22 09:04:48 dkf Exp $
*/
#include "tcl.h"
@@ -56,7 +56,7 @@ static char cvtIn[] = {
Tcl_WideUInt
strtoull(string, endPtr, base)
- char *string; /* String of ASCII digits, possibly
+ CONST char *string; /* String of ASCII digits, possibly
* preceded by white space. For bases
* greater than 10, either lower- or
* upper-case digits may be used.
@@ -70,7 +70,7 @@ strtoull(string, endPtr, base)
* else means decimal.
*/
{
- register char *p;
+ register CONST char *p;
register Tcl_WideUInt result = 0;
register unsigned digit;
register Tcl_WideUInt shifted;
@@ -81,7 +81,7 @@ strtoull(string, endPtr, base)
*/
p = string;
- while (isspace(*p)) { /* INTL: locale-dependent */
+ while (isspace(UCHAR(*p))) { /* INTL: locale-dependent */
p += 1;
}
@@ -229,7 +229,7 @@ strtoull(string, endPtr, base)
}
if (endPtr != 0) {
- *endPtr = p;
+ *endPtr = (char *) p;
}
return result;
@@ -251,7 +251,7 @@ strtoull(string, endPtr, base)
break;
}
}
- *endPtr = p;
+ *endPtr = (char *) p;
}
return (Tcl_WideUInt)Tcl_LongAsWide(-1);
}