Files
iverilog/ivtest/ivltests/sv_class_task_expr_fail.v
T
Lars-Peter Clausen 449abb6bda Add regression test for class tasks used as expressions
Check that using a class task through an object method call in expression
context reports a compile/elaboration error instead of triggering an assert.

Signed-off-by: Lars-Peter Clausen <[email protected]>
2026-06-20 17:06:36 -07:00

20 lines
234 B
Verilog

// Check that using a class task as an expression reports an error.
module test;
class C;
task t;
endtask
endclass
C c;
initial begin
int x;
c = new;
x = c.t();
$display("FAILED");
end
endmodule