parse_proc_arguments-args $args results ## 将参数保存到数组中,数组名为 results,数组元素名字是参数名,元素值是参数值if{ [array names results {-add}] !=""} { ## 匹配数组results 中符合正则表达式“{-add}”的元素名字,用于检测是否给出了 -add 参数 echo"add num $results(-add) !"## $resu...
} 其中在define_proc_attributes 中默认可选项都是 array 项,在函数主题中处理Opt ,先通过parse_proc_arguments -args $args opt 传递进来。 然后访问参量 set pattern $opt(-pattern) define_proc_attributes get_area \ -info "get_area for specified pattern" \ #cmd -help 打印出命令描述 -define_args ...
通过使用define_proc_attributes命令,可以 定义命令的help文档;声明参数生效的规则;预防进程被修改等 使用parse_proc_arguments命令联合define_proc_attributes命令定义进程中的-help选项以支持进程中参数的有效性。 Using the define_proc_attributes Command 使用synopsys中的define_proc_attributes命令定义以及改变进程的属性。
parse_proc_arguments -args $args results ## 将参数保存到数组中,数组名为 results,数组元素名字是参数名,元素值是参数值if { [array names results {-add}] != ""} { ## 匹配数组results 中符合正则表达式“{-add}”的元素名字,⽤于检测是否给出了 -add 参数 echo "add num $...
parse_proc_arguments命令将参数传递给由define_proc_attributes命令定义的进程的内部 在进程内部使用parse_proc_arguments命令支持参数的有效性,以使得-help选项有效。 Chapter4 Working with Collections Collection是一组设计对象的集合,例如libraries.ports,以及cells,通过使用synopsys提供的命令创建,观察和操作集合,本章将...
proc add {args} { ;# 解析参数, 并把结果放到变量results中, results是个array;# 注意这个命令需要与define_proc_atrributes联合使用,;# 否则会报告"Error: extra position option '-x_value'"等,;# 意思是这不知道如何解析这些参数.parse_proc_arguments -args$argsresults ...
procLevel The procedure call level. The command should be constructed in such a manner that it will work if additional arguments are added in the future. It is suggested that the command be a proc with the final argument being args. Tracing will be turned off while the command is being ex...
proc Event {sock} { global forever global pkt global peer set pkt [read $sock] set peer [fconfigure $sock -peer] puts "Received [string length $pkt] from $peer\n$pkt" set forever 1 return } set forever 0 # parse input arguments ...
The Tcl Core. (Mirror of core.tcl-lang.org) . Contribute to tcltk/tcl development by creating an account on GitHub.
{-xoffset "The distance to left_frame;Recommend value: 10." "value" float required} } proc addSupplyAboveMacro_byStripeMode {args} { parse_proc_arguments -args $args results set extension_distance $results(-extension_distance)set xoffsetNum $results(-xoffset)set xoffsetNum 10 s...