summaryrefslogtreecommitdiffstats
path: root/generic/tclUtil.c
diff options
context:
space:
mode:
authornijtmans <nijtmans>2009-02-10 23:08:56 (GMT)
committernijtmans <nijtmans>2009-02-10 23:08:56 (GMT)
commitbfcd65034eb86288bb554aef03df7c98101c3089 (patch)
treea407af9f40cff9d5a67f7ecf3a88b22578e0f842 /generic/tclUtil.c
parentb07274fff759a29a06f8c988c019d09d583fe435 (diff)
downloadtcl-bfcd65034eb86288bb554aef03df7c98101c3089.zip
tcl-bfcd65034eb86288bb554aef03df7c98101c3089.tar.gz
tcl-bfcd65034eb86288bb554aef03df7c98101c3089.tar.bz2
- eliminate some unnessary type casts
- some internal const decorations - spacing
Diffstat (limited to 'generic/tclUtil.c')
-rw-r--r--generic/tclUtil.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/generic/tclUtil.c b/generic/tclUtil.c
index bc189c0..9ea54b0 100644
--- a/generic/tclUtil.c
+++ b/generic/tclUtil.c
@@ -11,7 +11,7 @@
* See the file "license.terms" for information on usage and redistribution of
* this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tclUtil.c,v 1.108 2009/01/08 16:41:34 dkf Exp $
+ * RCS: @(#) $Id: tclUtil.c,v 1.109 2009/02/10 23:09:05 nijtmans Exp $
*/
#include "tclInt.h"
@@ -1146,7 +1146,7 @@ Tcl_ConcatObj(
{
int allocSize, finalSize, length, elemLength, i;
char *p;
- char *element;
+ const char *element;
char *concatStr;
Tcl_Obj *objPtr, *resPtr;
@@ -2561,7 +2561,8 @@ TclGetIntForIndex(
* representing an index. */
{
int length;
- char *opPtr, *bytes;
+ char *opPtr;
+ const char *bytes;
if (TclGetIntFromObj(NULL, objPtr, indexPtr) == TCL_OK) {
return TCL_OK;
@@ -2622,7 +2623,7 @@ TclGetIntForIndex(
parseError:
if (interp != NULL) {
- char *bytes = Tcl_GetString(objPtr);
+ const char *bytes = Tcl_GetString(objPtr);
/*
* The result might not be empty; this resets it which should be both
@@ -2705,7 +2706,7 @@ SetEndOffsetFromAny(
Tcl_Obj *objPtr) /* Pointer to the object to parse */
{
int offset; /* Offset in the "end-offset" expression */
- register char* bytes; /* String rep of the object */
+ register const char* bytes; /* String rep of the object */
int length; /* Length of the object's string rep */
/*