diff --git a/ivtest/ivltests/br_gh191_break.v b/ivtest/ivltests/br_gh191_break.v index 932a4277b..2a876a135 100644 --- a/ivtest/ivltests/br_gh191_break.v +++ b/ivtest/ivltests/br_gh191_break.v @@ -35,6 +35,18 @@ module main; $finish; end + idx = 0; + do begin + if (idx >= 2) + break; + idx += 1; + end while (idx < 5); + + if (idx != 2) begin + $display("FAILED -- break from do-while loop"); + $finish; + end + idx = 0; repeat (5) begin if (idx >= 2) diff --git a/ivtest/ivltests/br_gh191_continue.v b/ivtest/ivltests/br_gh191_continue.v index 3945e017c..a8fd4aa56 100644 --- a/ivtest/ivltests/br_gh191_continue.v +++ b/ivtest/ivltests/br_gh191_continue.v @@ -51,6 +51,21 @@ module main; $finish; end + idx = 0; + do begin + idx += 1; + if (idx < 2) + continue; + if (idx < 2) begin + $display("FAILED -- continue in do-while loop"); + $finish; + end + end while (idx < 5); + if (idx != 5) begin + $display("FAILED -- break from do-while loop"); + $finish; + end + idx = 0; repeat (5) begin idx += 1;