[sv-bc] Members of unpacked structures containing a union shall not be assigned individual default member values

From: Neil Korpusik <Neil.Korpusik_at_.....>
Date: Mon Jun 25 2007 - 18:53:05 PDT
<forwarding email from danielm@aldec.com>

It was originally sent to the sv-ec but it seems to belong in the sv-bc.

Neil



-------- Original Message --------
Subject: 	Members of unpacked structures containing a union shall not be
assigned individual default member values
Date: 	Mon, 25 Jun 2007 12:17:41 +0200
From: 	danielm <danielm@aldec.com.pl>
To: 	owner-sv-ec@eda.org



LRM 1800-2005 in chapter 4.11 - states:

"Members of unpacked structures containing a union as well as members of
packed structures shall not be assigned individual default member values."

There is no example  in LRM for above rule and I have doubts why it is
forbidden, and what in fact is forbidden?

Should below code fail on compilation because of this rule?

  module tb;

 struct { //structure containing a union
  bit a = 1;
  union { int c; int d; } n;
 } str1;

endmodule

????

DANiel





-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.
Received on Mon Jun 25 18:53:20 2007

This archive was generated by hypermail 2.1.8 : Mon Jun 25 2007 - 18:53:46 PDT