Contents Up << >>
Enumeration types
An object of an enumeration type may
take on a small number of values with explicit names. The definition
of an enumeration type is just a list of named values that an object
of that type can have. The grammar rule for the enumeration type definition
is:
Characters are typed in single quotes. For example, '$'
is a character. All of the literals in the definition must be unique.
The literals are represented internally by numbers indicating their
position in the list. There are attributes described later that
allow you to retrieve the position number of an enumeration literal and
the literal to the left or right of a particular literal. The boolean
character and bit types are enumeration types. Their definitions are
The characters above C159 are not available in this printing. They are the
standard characters found in the ISO 8859-1 character set, which provides
support for European languages. Characters that are not available in your
text editor can always be produced in your VHDL programs using the val
attribute. For example,
appends character 200 of the ISO 8859-1 character set to the string str.