diff options
author | stanton <stanton> | 1998-10-06 00:42:45 (GMT) |
---|---|---|
committer | stanton <stanton> | 1998-10-06 00:42:45 (GMT) |
commit | 0f8b9130ec96b8ef7ba2abe8b6d6a60cf98707fe (patch) | |
tree | dcdfa3b772b050b767c7c309cc59be2ab9dd2413 /generic | |
parent | 6c3b9fbc8dd3d4b1e53d0ceb7ba77ce239b43b28 (diff) | |
download | tcl-0f8b9130ec96b8ef7ba2abe8b6d6a60cf98707fe.zip tcl-0f8b9130ec96b8ef7ba2abe8b6d6a60cf98707fe.tar.gz tcl-0f8b9130ec96b8ef7ba2abe8b6d6a60cf98707fe.tar.bz2 |
added a warning about static string modifications
Diffstat (limited to 'generic')
-rw-r--r-- | generic/tclCompExpr.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/generic/tclCompExpr.c b/generic/tclCompExpr.c index c872698..0f494b9 100644 --- a/generic/tclCompExpr.c +++ b/generic/tclCompExpr.c @@ -8,7 +8,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclCompExpr.c,v 1.1.2.2 1998/09/24 23:58:43 stanton Exp $ + * RCS: @(#) $Id: tclCompExpr.c,v 1.1.2.3 1998/10/06 00:42:45 stanton Exp $ */ #include "tclInt.h" @@ -480,6 +480,13 @@ CompileSubExpr(exprTokenPtr, infoPtr, envPtr) * operator isn't found, treat it as a math function. */ + /* + * TODO: Note that the string is modified in place. This is unsafe + * and will break if any of the routines called while the string is + * modified have side effects that depend on the original string + * being unmodified (e.g. adding an etry to the literal table). + */ + operator = tokenPtr->start; savedChar = operator[tokenPtr->size]; operator[tokenPtr->size] = 0; |