ecarstens Posted July 9, 2012 Report Share Posted July 9, 2012 I extended uvm_algorithmic_comparator class and had some trouble writing its constructor because it insisted that I call super.new first before doing anything else in the body of the constructor function. The problem was I needed the transformer object created first before calling super.new. My solution was to create the transform object in the argument list of my constructor, rather than trying to do it in the body of the function: function new(string name, uvm_component parent=null, alu_op_to_result transformer=new()); This worked and the tool allowed it. Just wanted to share this trick with the forum. -Ed enriquext11 1 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.