summaryrefslogtreecommitdiffstats
path: root/generic
diff options
context:
space:
mode:
authorandreask <andreask>2012-02-17 17:12:32 (GMT)
committerandreask <andreask>2012-02-17 17:12:32 (GMT)
commit76adf66e550eb63f49a19c9ada4e49123efea2ec (patch)
tree8385a257c88c99182bada5df7395d8fd41dc5f93 /generic
parent6df0a0efa540b67adb5a9d1bb2c5f58f8f656e23 (diff)
downloadtcl-76adf66e550eb63f49a19c9ada4e49123efea2ec.zip
tcl-76adf66e550eb63f49a19c9ada4e49123efea2ec.tar.gz
tcl-76adf66e550eb63f49a19c9ada4e49123efea2ec.tar.bz2
Fix: Removed C99ism (in-block variable declaration) from commit [39f6ebe301] which prevents building with non-gcc compilers, notably AIX, HPUX, Solaris, MSVC6, possibly others.
Diffstat (limited to 'generic')
-rw-r--r--generic/tclCompile.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/generic/tclCompile.c b/generic/tclCompile.c
index 59d1fbf..9b23389 100644
--- a/generic/tclCompile.c
+++ b/generic/tclCompile.c
@@ -4091,11 +4091,13 @@ RecordByteCodeStats(
* to add to accumulated statistics. */
{
Interp *iPtr = (Interp *) *codePtr->interpHandle;
+ register ByteCodeStats *statsPtr;
+
if (iPtr == NULL) {
/* Avoid segfaulting in case we're called in a deleted interp */
return;
}
- register ByteCodeStats *statsPtr = &(iPtr->stats);
+ statsPtr = &(iPtr->stats);
statsPtr->numCompilations++;
statsPtr->totalSrcBytes += (double) codePtr->numSrcBytes;