mirror of
https://github.com/steveicarus/iverilog.git
synced 2026-08-29 01:03:29 +02:00
Add regression test for super access error
Check that access through `super` is rejected when the current class has no parent class. Signed-off-by: Lars-Peter Clausen <[email protected]>
This commit is contained in:
@@ -0,0 +1,11 @@
|
||||
// Check that `super` access in a class without a parent class is rejected.
|
||||
|
||||
module test;
|
||||
|
||||
class C;
|
||||
function void f;
|
||||
super.x = 1;
|
||||
endfunction
|
||||
endclass
|
||||
|
||||
endmodule
|
||||
@@ -288,6 +288,7 @@ sv_package_lifetime vvp_tests/sv_package_lifetime.json
|
||||
sv_package_lifetime_fail vvp_tests/sv_package_lifetime_fail.json
|
||||
sv_parameter_type vvp_tests/sv_parameter_type.json
|
||||
sv_queue_assign_op vvp_tests/sv_queue_assign_op.json
|
||||
sv_super_member_fail vvp_tests/sv_super_member_fail.json
|
||||
sv_wildcard_import8 vvp_tests/sv_wildcard_import8.json
|
||||
sdf_header vvp_tests/sdf_header.json
|
||||
task_return1 vvp_tests/task_return1.json
|
||||
|
||||
@@ -0,0 +1,5 @@
|
||||
{
|
||||
"type" : "CE",
|
||||
"source" : "sv_super_member_fail.v",
|
||||
"iverilog-args" : [ "-g2005-sv" ]
|
||||
}
|
||||
Reference in New Issue
Block a user