Reputation: 13
I am a beginner with tcl. I am trying to use primetime execute command, but it can't accept variable. For example:
set var "get_timing_paths -rise_from A -rise_to B"
set path0001 [$var]
But it doesn't work. The things I want to do is
set path0001 [get_timing_paths -rise_from A -rise_to B]
but I need to seperate it.
Thank you for your answer.
Upvotes: 1
Views: 3039
Reputation: 611
If you're using Tcl/Tk 8.5 or newer, it'd be better to use the list expansion operator {*}
instead of eval
:
set var "get_timing_paths -rise_from A -rise_to B"
set path0001 [{*}$var]
It's a bit faster and safer.
Upvotes: 5