and then
OK_To_Rename_Entity_Name (Prefix (Expr_Q)))));
begin
- -- ??? Return False if there are any aspect specifications, because
- -- otherwise we duplicate that corresponding implicit attribute
- -- definition, and call Insert_Action, which has no place to insert
- -- the attribute definition. The attribute definition is stored in
- -- Aspect_Rep_Item, which is not a list.
+ return Result
- return Result and then No (Aspect_Specifications (N));
+ -- The declaration cannot be rewritten if it has got constraints,
+ -- in other words the nominal subtype must be unconstrained.
+
+ and then Is_Entity_Name (Original_Node (Obj_Def))
+
+ -- ??? Return False if there are any aspect specifications, because
+ -- otherwise we duplicate that corresponding implicit attribute
+ -- definition, and call Insert_Action, which has no place to insert
+ -- the attribute definition. The attribute definition is stored in
+ -- Aspect_Rep_Item, which is not a list.
+
+ and then No (Aspect_Specifications (N));
end Rewrite_As_Renaming;
-- Local variables
-- Note: The Actions field temporarily holds any actions associated with
-- evaluation of the Expression. During expansion of the case expression
- -- these actions are wrapped into an N_Expressions_With_Actions node
+ -- these actions are wrapped into an N_Expression_With_Actions node
-- replacing the original expression.
-- Note: this node never appears in the tree passed to the back end,