Question: Identify the Error in the system verilig code and Rectify It class transaction _ A; bit [ 3 1 : 0 ] data; int id;

Identify the Error in the system verilig code and Rectify It
class transaction_A;
bit [31:0] data;
int id;
transaction_B tr_B = new();
function void display();
$display("transaction_A: data =%0d and id =%0d", data, id);
$display("transaction_B: addr =%0d", tr_B.addr);
endfunction
endclass
class transaction_B;
bit [31:0] addr =200;
endclass
module class_example;
initial begin
tr_A = new();
tr_A.data =100;
tr_A.id =1;
tr_A.display();
end
endmodule

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!