Subject: [sv-bc] error in example in section 2.7
From: Paul Graham (pgraham@cadence.com)
Date: Fri Jan 09 2004 - 13:46:37 PST
Section 2.7 has an example of a type cast of an array:
If the type is not given by the context, it must be specified with a
cast.
typedef int [1:3] triple; // 3 integers packed together
b = triple'{0, 1, 2};
Type triple is a packed array type. This means it is a singular type. A
concat seen in the context of a singular type is an ordinary concat, not an
array literal, and therefore may not contain an unsigned integer.
To fix this example you can either 1) define triple as an unpacked array
type, or 2) use something other than unsized integers in the concat.
Paul
This archive was generated by hypermail 2b28 : Fri Jan 09 2004 - 13:52:44 PST