Tcl Source Code

View Ticket
Login
Ticket UUID: 696707
Title: trace command on 'env' bug
Type: Bug Created on: 2003-03-03 17:25:17
Submitter: tomk Assigned to: hobbs
Subsystem: 08. Environment Variables Severity:
Priority: 5 Medium Last modified: 2004-09-21 05:20:46
Status: Open Closed by:
Resolution: None Closed on:
Version: obsolete: 8.4.2
Description:
The trace command doesn't work on the env array.

% tclsh 
% info tclversion
8.4
% array set X {}
% proc XValChx {a e op} { if {![info exists ::X($e)]}
{set ::X($e) $e}}
% trace var X r XValChx
% puts "X: $X(TEST)"
X: TEST
% array set env {}
% proc EnvValChx {a e op} {if {![info exists
::env($e)]} {set ::env($e) $e}}
% trace var env r EnvValChx
% puts "ENV: $env(TEST2)"
can't read "env(TEST2)": no such variable