User guide

24-152
SystemVerilog Testbench Constructs
$display("Aspect_2: send advice after\n");
endtask
task send_around_Created_c();
send_before_Created_d();
$display("Aspect_3: Begin send advice around\n");
send_after_Created_a();
$display("Aspect_3: End send advice around\n");
endtask
task send_before_Created_d();
$display("Aspect_3: send advice before\n");
endtask
task send_after_Created_e();
$display("Aspect_1: send advice after\n");
endtask
task send_Created_f();
send_around_Created_c();
send_after_Created_e()
endtask
endclass
// End of file Input.sv
This Example 24-15 shows the input program after weaving of all
four advices {2, 3, 4, 1}. New methods send_after_Created_e and
send_Created_f are created in the last step of weaving and the
instances of method call to packet::send_around_Created_c were
replaced by method call to packet::send_Created_f.
When executed, output of this program is:
Aspect_3: send advice before
Aspect_3: Begin send advice around
Sending data
Aspect_2: send advice after
Aspect_3: End send advice around
Aspect_1: send advice after
Examples of code containing around advice