Newbie level 1
Each of these functions are in a separate derived class extending ... lets say uvm_test
In example 1, we use virtual when overriding an already virtual method, in example 2, we do not use the virtual keyword... I have seen examples both ways and no one seems to explain the usage of virtual in these specific cases. Is this a matter of style or is there a reason for using/not using the virtual keyword here? Can someone explain this to me? Thank you.
//example 1 class AAA extends uvm_test //code... virtual function void build_phase (uvm_phase phase) //code... endfunction //code... endclass
//example 2 class BBB extends uvm_test //code... function void build_phase (uvm_phase phase) //code... endfunction //code... endclass