@@ -69,6 +69,8 @@ static IdString is_type_parameter;
6969/* static*/ const IdString &UhdmAst::is_simplified_wire () { return attr_id::is_simplified_wire; }
7070/* static*/ const IdString &UhdmAst::low_high_bound () { return attr_id::low_high_bound; }
7171
72+ #define MAKE_INTERNAL_ID (X ) IdString(" $systemverilog_plugin$" #X)
73+
7274void attr_id_init ()
7375{
7476 // Initialize only once
@@ -80,14 +82,14 @@ void attr_id_init()
8082
8183 // Register IdStrings. Can't be done statically, as the IdString class uses resources created during Yosys initialization which happens after
8284 // static initialization of the plugin when everything is statically linked.
83- attr_id::partial = IdString ( " $systemverilog_plugin$ partial" );
84- attr_id::packed_ranges = IdString ( " $systemverilog_plugin$ packed_ranges" );
85- attr_id::unpacked_ranges = IdString ( " $systemverilog_plugin$ unpacked_ranges" );
86- attr_id::force_convert = IdString ( " $systemverilog_plugin$ force_convert" );
87- attr_id::is_imported = IdString ( " $systemverilog_plugin$ is_imported" );
88- attr_id::is_simplified_wire = IdString ( " $systemverilog_plugin$ is_simplified_wire" );
89- attr_id::low_high_bound = IdString ( " $systemverilog_plugin$ low_high_bound" );
90- attr_id::is_type_parameter = IdString ( " $systemverilog_plugin$ is_type_parameter" );
85+ attr_id::partial = MAKE_INTERNAL_ID ( partial);
86+ attr_id::packed_ranges = MAKE_INTERNAL_ID ( packed_ranges);
87+ attr_id::unpacked_ranges = MAKE_INTERNAL_ID ( unpacked_ranges);
88+ attr_id::force_convert = MAKE_INTERNAL_ID ( force_convert);
89+ attr_id::is_imported = MAKE_INTERNAL_ID ( is_imported);
90+ attr_id::is_simplified_wire = MAKE_INTERNAL_ID ( is_simplified_wire);
91+ attr_id::low_high_bound = MAKE_INTERNAL_ID ( low_high_bound);
92+ attr_id::is_type_parameter = MAKE_INTERNAL_ID ( is_type_parameter);
9193}
9294
9395void attr_id_cleanup ()
0 commit comments