From ce6c10424834a81beb5c714d76a1bd6670d320b5 Mon Sep 17 00:00:00 2001 From: dgp Date: Tue, 6 Sep 2011 20:37:58 +0000 Subject: Don't extend numbers with non-alphanumeric characters into barewords. --- generic/tclCompExpr.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/generic/tclCompExpr.c b/generic/tclCompExpr.c index 077d595..3fdcc22 100644 --- a/generic/tclCompExpr.c +++ b/generic/tclCompExpr.c @@ -1932,6 +1932,12 @@ ParseLexeme( return (end-start); } else { unsigned char lexeme; + const char *p = start; + while (p < end) { + if (!isalnum(UCHAR(*p++))) { + goto number; + } + } ParseLexeme(end, numBytes-(end-start), &lexeme, NULL); if ((NODE_TYPE & lexeme) == BINARY) { goto number; -- cgit v0.12