System verilog code output

Status
Not open for further replies.

sunidrak

Full Member level 1
Joined
Apr 12, 2012
Messages
97
Helped
2
Reputation
4
Reaction score
2
Trophy points
1,288
Location
Bengaluru, India
Activity points
1,738
hi all,

How to cheak output of this code in Modelsim, I am not getting any output neither in transcript window nor in wave window ,Please explain how to check this code output


virtual class A ;
virtual task disp ();
$display(" This is class A ");
endtask
endclass

class EA extends A ;
task disp ();
$display(" This is Extended class A ");
endtask
endclass

program main ;
EA my_ea;
A my_a;
initial
begin
my_ea = new();
my_a = my_ea;
my_ea.disp();
my_a.disp();
end
endprogram
 

Status
Not open for further replies.
Cookies are required to use this site. You must accept them to continue using the site. Learn more…