Hi, I have below script to setup compare file list. set CompareList(test_1) [ list \ ${FILENAME_PREFIX}_r_0_input.txt \ # ${FILENAME_PREFIX}_r_0_output.txt ] set CompareList(test_top) [ list \ ${FILENAME_PREFIX}_input.txt \ ${FILENAME_PREFIX}_output.txt ] if { $BLOCK != "test_top" } { upvar 0 CompareList($BLOCK) Compare_List } else { set Compare_List {} foreach b [split $BlockList ":"] { upvar 0 CompareList($b) one_list set Compare_List [concat $Compare_List $one_list] } } Nagelfar reports: Found...
Tried adding quotes: upvar 0 CompareList($BLOCK) "Compare_List" But still see the warning message. How can we remove the warning without changing the code? Like if user can ignore any checking rules? Seems I can ignore the warning by commented out syntaxdb.tcl, line 3231: # errorMsg W "Found constant \"$varBase\" which is also a\ variable." [lindex $indices $i] In the beginning, I defined current BLOCK name and block list. set BLOCK "test_top" set BlockList "test_1:test_2:..." Each block's file checking...
Tried adding quotes: upvar 0 CompareList($BLOCK) "Compare_List" But still see the warning message. How can we remove the warning without changing the code? Like if user can ignore any checking rules? In the beginning, I defined current BLOCK name and block list. set BLOCK "test_top" set BlockList "test_1:test_2:..." Each block's file checking list is defined by "set CompareList(xxx)". "upvar" is check out current block's check list and assigned it to current compare list: "Compare_List". For the...
The procExists is used as below. It check if proc Force_Random_Staller_Seed is exist. If yes, it will force the random staller seed. if {[procExists Force_Random_Staller_Seed]} { Force_Random_Staller_Seed } "info procs" will return procs' name if found, so whole "expr" is to evaluate whether proc is defined or not and assigned value 1 or 0. uplevel 1 is to evalue it in the top level. So basically as its name, it's check whether proc is defined or not. I think here it's a corner case not covered by...
Is there a way to let user ignore any checking rules? In the beginning, I defined current BLOCK name and block list. set BLOCK "test_top" set BlockList "test_1:test_2:..." Each block's file checking list is defined by "set CompareList(xxx)". "upvar" is check out current block's check list and assigned it to current compare list: "Compare_List". For the top level test, it shall contain all block check lists. So there is a foreach loop to go through all block's check list. Yes, you are right, line...
Yes, you are right, line 3 is an error. Because when copying the code, I removed one line, real code looks like below. set CompareList(test_1) [ list \ ${FILENAME_PREFIX}_r_0_input.txt \ # ${FILENAME_PREFIX}_XXX_output.txt \ # ${FILENAME_PREFIX}_r_0_output.txt ]
Hi, I have below proc to check if a proc exists. proc procExists p { return uplevel 1 [expr {[llength [info procs $p]] > 0}] } Nagelfar reports: Wrong number of arguments (3) to "return". Is this a bug? Thanks!
Hi, I have below script to setup compare file list. set CompareList(test_1) [ list \ ${FILENAME_PREFIX}_r_0_input.txt \ # ${FILENAME_PREFIX}_r_0_output.txt ] set CompareList(test_top) [ list \ ${FILENAME_PREFIX}_input.txt \ ${FILENAME_PREFIX}_output.txt ] if { $BLOCK != "test_top" } { upvar 0 CompareList($BLOCK) Compare_List } else { foreach b [split $BlockList ":"] { upvar 0 CompareList($b) one_list set Compare_List [concat $Compare_List $one_list] } } Nagelfar reports: Found constant "CompareList"...