[sv-bc] Another question about enums


Subject: [sv-bc] Another question about enums
From: Francoise Martinolle (fm@cadence.com)
Date: Fri Oct 31 2003 - 10:05:28 PST


The spec says that if unspecified in the data type declaration, the size of
the enumeration type can be implicitly derived from the values of the
enumeration constants provided.

The spec does not say anything about the signedness.
Should'nt the signedness also be derived from the constant value?
Ex:
typedef enum { p, r = 4'sh5 /* note s for signed */ } enumtype;

The width is 4, it is 2-state. Is it signed?

Francoise
       '



This archive was generated by hypermail 2b28 : Fri Oct 31 2003 - 10:07:52 PST