aboutsummaryrefslogtreecommitdiff
path: root/gcc/ada/exp_ch6.ads
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/ada/exp_ch6.ads')
-rw-r--r--gcc/ada/exp_ch6.ads10
1 files changed, 7 insertions, 3 deletions
diff --git a/gcc/ada/exp_ch6.ads b/gcc/ada/exp_ch6.ads
index 272f893..76cec4d 100644
--- a/gcc/ada/exp_ch6.ads
+++ b/gcc/ada/exp_ch6.ads
@@ -6,7 +6,7 @@
-- --
-- S p e c --
-- --
--- Copyright (C) 1992-2020, Free Software Foundation, Inc. --
+-- Copyright (C) 1992-2021, Free Software Foundation, Inc. --
-- --
-- GNAT is free software; you can redistribute it and/or modify it under --
-- terms of the GNU General Public License as published by the Free Soft- --
@@ -32,6 +32,7 @@ package Exp_Ch6 is
procedure Expand_N_Extended_Return_Statement (N : Node_Id);
procedure Expand_N_Function_Call (N : Node_Id);
procedure Expand_N_Procedure_Call_Statement (N : Node_Id);
+ procedure Expand_N_Return_When_Statement (N : Node_Id);
procedure Expand_N_Simple_Return_Statement (N : Node_Id);
procedure Expand_N_Subprogram_Body (N : Node_Id);
procedure Expand_N_Subprogram_Body_Stub (N : Node_Id);
@@ -133,8 +134,11 @@ package Exp_Ch6 is
--
-- For inherently limited types in Ada 2005, True means that calls will
-- actually be build-in-place in all cases. For other types, build-in-place
- -- will be used when possible, but we need to make a copy at the call site
- -- in some cases, notably assignment statements.
+ -- will be used when possible, but we need to make a copy in some
+ -- cases. For example, for "X := F(...);" if F can see X, or if F can
+ -- propagate exceptions, we need to store its result in a temp in general,
+ -- and copy the temp into X. Also, for "return Global_Var;" Global_Var
+ -- needs to be copied into the function result object.
function Is_Build_In_Place_Function (E : Entity_Id) return Boolean;
-- Ada 2005 (AI-318-02): Returns True if E denotes a function, generic