6.4 Standard Enumeration Types: Characters - JulTob/Ada GitHub Wiki
The other predefined enumeration types are Character
, Wide_Character
and Wide_Wide_Character
whose values are the 8-bit ISO Latin-1
, the 16-bit ISO Basic Multilingual Plane
and the full 32-bit ISO 10646 characters
;
These types naturally play an important role in input–output.
Their literal values include the printable characters and these are represented by placing them in single quotes thus 'X' or 'a' or indeed '''.
subtype Letter is Character;
---------------------------------------
subtype Letter is Wide_Character;
---------------------------------------
subtype Letter is Wide_Wide_Character;
---------------------------------------
My_Letter: Letter := 'a'
The values correspond to the ISO standard ISO/IEC 10646:2003-Latin-1
type Dígito_Romano is ('I', 'V', 'X', 'L', 'C', 'D', 'M');
Pi : constant Character := 'Π';