Tipos derivados

Explicación

Un tipo derivado es uno cuyas características se derivan de las de un tipo antecesor (parent).

Sintaxis

derived_type_full_type_declaration ::= 
     type defining_identifier [known_discriminant_part] is derived_type_definition;
derived_type_definition ::= 
   [abstract] [limited] new parent_subtype_indication [[and interface_list] record_extension_part]

Ejemplo

type Semana is (Lun, Mar, Mie, Jue, Vie, Sab, Dom);
---------------------------------------------------
type Laborables is new Semana range Lun .. Vie;
type Entero is new Integer;
type Entero_Corto is new Integer range -256 .. 255;
type Contador is new Natural;