Specman 中是否有reduce()
可用于一般归约函数的列表方法?我在想类似的东西:
var x: list of bit = some_function_that_returns_list_of_bit;
var bitmap: uint = x.reduce(foo());
wherereduce()
像在 Python 中一样工作:
foo(last: uint, val: bit) is: uint {
return (last << 1 ) | bit;
};