Forum Discussion
Altera_Forum
Honored Contributor
9 years agoWill Quartus ever support Verilog hierarchical parameter referencing?
Hello, module p { parameter x = some expresssion; ... } p p_inst(); localparam x = p.x; This would be really useful i.e. read as essential for what I am trying to do. A...
Altera_Forum
Honored Contributor
9 years agoI have a similar problem. I organize the parameters into a struct, and then pass the struct. as a parameter into an interface.
typedef struct packed { int unsigned DATA_WIDTH; int unsigned ADDR_WIDTH; } cfg_s; interface some_if # (parameter cfg_s CFG = some_if_pkg::CFG_DEFAULT) when trying to access CFG.DATA_WIDTH, I get a "constant expression cannot contain a hierarchical identifier." from quartus Questa has no problems with this.