-- DISCRIMINANT_SPECIFICATION ::=
-- DEFINING_IDENTIFIER_LIST : [NULL_EXCLUSION] SUBTYPE_MARK
- -- [:= DEFAULT_EXPRESSION]
+ -- [:= DEFAULT_EXPRESSION] [ASPECT_SPECIFICATION]
-- | DEFINING_IDENTIFIER_LIST : ACCESS_DEFINITION
- -- [:= DEFAULT_EXPRESSION]
+ -- [:= DEFAULT_EXPRESSION] [ASPECT_SPECIFICATION]
-- If no known discriminant part is present, then No_List is returned
Set_Expression
(Specification_Node, Init_Expr_Opt (True));
+ if Token = Tok_With then
+ P_Aspect_Specifications (Specification_Node, False);
+ end if;
+
if Ident > 1 then
Set_Prev_Ids (Specification_Node, True);
end if;
--
-- EXTENDED_RETURN_STATEMENT ::=
-- return DEFINING_IDENTIFIER : [aliased] RETURN_SUBTYPE_INDICATION
- -- [:= EXPRESSION] [do
+ -- [:= EXPRESSION]
+ -- [ASPECT_SPECIFICATION] [do
-- HANDLED_SEQUENCE_OF_STATEMENTS
-- end return];
--
Ret_Sloc : constant Source_Ptr := Token_Ptr;
Ret_Strt : constant Column_Number := Start_Column;
Ret_Node : Node_Id;
+ Decl : Node_Id;
-- Start of processing for P_Return_Statement
end if;
Ret_Node := New_Node (N_Extended_Return_Statement, Ret_Sloc);
- Set_Return_Object_Declarations
- (Ret_Node, New_List (P_Return_Object_Declaration));
+ Decl := P_Return_Object_Declaration;
+ Set_Return_Object_Declarations (Ret_Node, New_List (Decl));
+
+ if Token = Tok_With then
+ P_Aspect_Specifications (Decl, False);
+ end if;
if Token = Tok_Do then
Push_Scope_Stack;
-- ENTRY_INDEX_SPECIFICATION ::=
-- for DEFINING_IDENTIFIER in DISCRETE_SUBTYPE_DEFINITION
+ -- [ASPECT_SPECIFICATION]
-- Error recovery: can raise Error_Resync
T_In;
Set_Discrete_Subtype_Definition
(Iterator_Node, P_Discrete_Subtype_Definition);
+
+ if Token = Tok_With then
+ P_Aspect_Specifications (Iterator_Node, False);
+ end if;
+
return Iterator_Node;
end P_Entry_Index_Specification;