User guide

24-141
SystemVerilog Testbench Constructs
Weaving of the advice in the target method yields the following.
task myTask_around();
$display("Around in aoe1\n");
endtask
task myTask();
$display("Executing original code\n");
endtask
As a result of weaving, all the method calls to myTask() in the input
program code are replaced by method calls to myTask_around().
Also, myTask_around() replaces myTask() as the target method for
myTask().
During weaving of an around advice that contains a proceed
statement, the proceed statement is replaced by a method call to
the target method.
Example 24-10
Target method:
task myTask();
$display("Executing original code\n");
endtask
Advice:
around task myTask ();
proceed;
$display("Around in aoe1\n");
endtask