In reply to Coppola:
My router env has a background sequence “seq”, which has been defined to be of type router_base_seq.
From the test, i am trying to over-ride it to be of type router_012_seq.
Over-riding by type is working fine. However, override by instance name is not working.
I am calling the below after router_env has been created.
Case 1: router_base_seq::type_id::set_type_override(router_012_seq::get_type());
Case 2: router_base_seq::type_id::set_inst_override(router_012_seq::get_type(), “router_env.seq”);
Any idea on what is wrong with Case 2?
Thanks!
Your case 2 is wrong. The hierarchical path points to the sequencer and not to the sequence.
I believe there is no value in constructing a ‘sequence architecture’. This would be in contrast or an alternative to the inheritence of object-oriented programming.
It is more easy and obvious to create/extend another sequence with the required behavior instead of overriding a certain sequence object.