aboutsummaryrefslogtreecommitdiff
path: root/gcc/ada/sem_ch6.adb
diff options
context:
space:
mode:
authorYannick Moy <moy@adacore.com>2023-10-16 12:24:46 +0200
committerMarc Poulhiès <poulhies@adacore.com>2023-11-07 10:15:04 +0100
commit36fcb4b93003d9eb135564d3eb0d07f27a3e2c47 (patch)
treef81291ebf4ba597c2ef6919f8e508f899dfed52a /gcc/ada/sem_ch6.adb
parent76bf4321331b1d453555602407029344e1e1ee4a (diff)
downloadgcc-36fcb4b93003d9eb135564d3eb0d07f27a3e2c47.zip
gcc-36fcb4b93003d9eb135564d3eb0d07f27a3e2c47.tar.gz
gcc-36fcb4b93003d9eb135564d3eb0d07f27a3e2c47.tar.bz2
ada: Rename Is_Limited_View to reflect actual query
Function Sem_Aux.Is_Limited_View returns whether the type is "inherently limited" in a slightly different way from the "immutably limited" definition in Ada 2012. Rename for clarity. gcc/ada/ * exp_aggr.adb: Apply the renaming. * exp_ch3.adb: Same. * exp_ch4.adb: Same. * exp_ch6.adb: Same. * exp_ch7.adb: Same. * exp_util.adb: Same. * freeze.adb: Same. * sem_aggr.adb: Same. * sem_attr.adb: Same. * sem_aux.adb: Alphabetize Is_Limited_Type. Rename. * sem_aux.ads: Same. * sem_ch3.adb: Apply the renaming. * sem_ch6.adb: Same. * sem_ch8.adb: Same. * sem_prag.adb: Same. * sem_res.adb: Same. * sem_util.adb: Same.
Diffstat (limited to 'gcc/ada/sem_ch6.adb')
-rw-r--r--gcc/ada/sem_ch6.adb6
1 files changed, 3 insertions, 3 deletions
diff --git a/gcc/ada/sem_ch6.adb b/gcc/ada/sem_ch6.adb
index 3dd2659..4f2521a 100644
--- a/gcc/ada/sem_ch6.adb
+++ b/gcc/ada/sem_ch6.adb
@@ -1065,7 +1065,7 @@ package body Sem_Ch6 is
-- get generated elsewhere.
if (Ada_Version < Ada_2005 or else Debug_Flag_Dot_L)
- and then Is_Limited_View (Etype (Scope_Id))
+ and then Is_Inherently_Limited_Type (Etype (Scope_Id))
and then Static_Accessibility_Level (Expr, Zero_On_Dynamic_Level)
> Subprogram_Access_Level (Scope_Id)
then
@@ -6662,7 +6662,7 @@ package body Sem_Ch6 is
("(Ada 2005) cannot copy object of a limited type "
& "(RM-2005 6.5(5.5/2))", Expr);
- if Is_Limited_View (R_Type) then
+ if Is_Inherently_Limited_Type (R_Type) then
Error_Msg_N
("\return by reference not permitted in Ada 2005", Expr);
end if;
@@ -6682,7 +6682,7 @@ package body Sem_Ch6 is
("return of limited object not permitted in Ada 2005 "
& "(RM-2005 6.5(5.5/2))?y?", Expr);
- elsif Is_Limited_View (R_Type) then
+ elsif Is_Inherently_Limited_Type (R_Type) then
Error_Msg_N
("return by reference not permitted in Ada 2005 "
& "(RM-2005 6.5(5.5/2))?y?", Expr);