[sv-bc] Is interface ref variable automatic?

From: Surya Pratik Saha <spsaha_at_.....>
Date: Wed Dec 12 2007 - 05:55:14 PST
Hi,

Consider the following testcase,

interface intf (ref bit [3:0] ba);
endinterface

module named1 ();
   bit [3:0] ba;
   assign o1 =  i2.ba;
   intf i2 (ba);
endmodule

As per systemverilog LRM 1800-2005, section 12.4.2 Pass by reference:

"Because a variable passed by reference may be an automatic variable, a ref
argument shall not be used in any context forbidden for automatic 
variables."

Could you please tell me whether the above testcase is erroneous or not?
I guess, it is erroneous because ref variable(which should be treated as
automatic variable) is hierarchically referred(i2.ba).

-- 
Regards
Surya






-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.
Received on Thu Dec 13 06:24:08 2007

This archive was generated by hypermail 2.1.8 : Thu Dec 13 2007 - 06:25:43 PST