aboutsummaryrefslogtreecommitdiff
path: root/gcc/cfgexpand.c
diff options
context:
space:
mode:
authorEd Schonberg <schonberg@adacore.com>2021-03-27 23:28:29 -0400
committerPierre-Marie de Rodat <derodat@adacore.com>2021-06-21 06:45:13 -0400
commitc3681eba728a487f042de72e90c29b1cfca4e2e7 (patch)
treeae1f6f76a8f2f58aabe16968cf238ed88029feaf /gcc/cfgexpand.c
parent336438b6d225c3a5f28d57fd766e36f53faf8f3e (diff)
downloadgcc-c3681eba728a487f042de72e90c29b1cfca4e2e7.zip
gcc-c3681eba728a487f042de72e90c29b1cfca4e2e7.tar.gz
gcc-c3681eba728a487f042de72e90c29b1cfca4e2e7.tar.bz2
[Ada] Implementation of AI12-205: defaults for formal types
gcc/ada/ * gen_il-fields.ads: Add Default_Subtype_Mark to enumeration type for fields. * gen_il-gen-gen_nodes.adb: Add call to create new field for Formal_Type_Declaration node. * par-ch12.adb (P_Formal_Type_Declaration): in Ada_2022 mode, recognize new syntax for default: "or use subtype_mark". (P_Formal_Type_Definition): Ditto for the case of a formal incomplete type. * sinfo.ads: Add field Default_Subtype_Mark to N_Formal_Type_Declaration. * sem_ch12.adb (Validate_Formal_Type_Default): New procedure, to apply legality rules to default subtypes in formal type declarations. Some legality rules apply to all defaults, such as the requirement that the default for a formal type that depends on previous formal entities must itself be a previously declared formal of the same unit. Other checks are kind- specific. (Analyze_Associations): Use specified default if there is no actual provided for a formal type in an instance. (Analyze_Formal_Type_Declaration): Call Validate_Formal_Type_Default when default subtype is present.
Diffstat (limited to 'gcc/cfgexpand.c')
0 files changed, 0 insertions, 0 deletions