Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
例如,
模块 MM;
毫米毫米[128]();
我想得到 mm[i].signle1,i 从 0 到 120。但我不能使用“for”,而且我不想写 120 条语句。
我能做些什么?
您可以创建端口列表,并且可以使用 for 循环:
signals : list of simple_port of bit is instance; keep signals.size() == 128; keep for each (s) in signals { s.hdl_path() == append("mm[",dec(i),"].signal1"); };