aboutsummaryrefslogtreecommitdiff
path: root/gcc/ada/sem_ch3.adb
diff options
context:
space:
mode:
authorRobert Dewar <dewar@adacore.com>2014-07-29 12:56:31 +0000
committerArnaud Charlet <charlet@gcc.gnu.org>2014-07-29 14:56:31 +0200
commitedab608853d34224b204dc42d751a3f90daabe39 (patch)
tree6cc8f3aef60cefb58f69e4a2c8d62232b4c13f10 /gcc/ada/sem_ch3.adb
parentc5c780e6deb9cf337f4898db5716659698311d7d (diff)
downloadgcc-edab608853d34224b204dc42d751a3f90daabe39.zip
gcc-edab608853d34224b204dc42d751a3f90daabe39.tar.gz
gcc-edab608853d34224b204dc42d751a3f90daabe39.tar.bz2
sem_aggr.adb (Resolve_Array_Aggregate): Change Is_Static_Range to Is_OK_Static_Range.
2014-07-29 Robert Dewar <dewar@adacore.com> * sem_aggr.adb (Resolve_Array_Aggregate): Change Is_Static_Range to Is_OK_Static_Range. * sem_attr.adb (Eval_Attribute): Make sure we properly flag static attributes (Eval_Attribute, case Size): Handle size of zero properly (Eval_Attribute, case Value_Size): Handle size of zero properly. * sem_ch13.adb: Minor reformatting. * sem_ch3.adb (Process_Range_Expr_In_Decl): Change Is_Static_Range to Is_OK_Static_Range. * sem_eval.adb (Eval_Case_Expression): Total rewrite, was wrong in several ways (Is_Static_Range): Moved here from spec (Is_Static_Subtype): Moved here from spec Change some incorrect Is_Static_Subtype calls to Is_OK_Static_Subtype. * sem_eval.ads: Add comments to section on Is_Static_Expression/Raises_Constraint_Error (Is_OK_Static_Range): Add clarifying comments (Is_Static_Range): Moved to body (Is_Statically_Unevaluated): New function. * sem_util.ads, sem_util.adb (Is_Preelaborable_Expression): Change Is_Static_Range to Is_OK_Static_Range. * sinfo.ads: Additional commments for Is_Static_Expression noting that clients should almost always use Is_OK_Static_Expression instead. Many other changes throughout front end units to obey this rule. * tbuild.ads, tbuild.adb (New_Occurrence_Of): Set Is_Static_Expression for enumeration literal. * exp_ch5.adb, sem_intr.adb, sem_ch5.adb, exp_attr.adb, exp_ch9.adb, lib-writ.adb, sem_ch9.adb, einfo.ads, checks.adb, checks.ads, sem_prag.adb, sem_ch12.adb, freeze.adb, sem_res.adb, exp_ch4.adb, exp_ch6.adb, sem_ch4.adb, sem_ch6.adb, exp_aggr.adb, sem_cat.adb: Replace all occurrences of Is_Static_Expression by Is_OK_Static_Expression. From-SVN: r213159
Diffstat (limited to 'gcc/ada/sem_ch3.adb')
-rw-r--r--gcc/ada/sem_ch3.adb6
1 files changed, 3 insertions, 3 deletions
diff --git a/gcc/ada/sem_ch3.adb b/gcc/ada/sem_ch3.adb
index 1f89f2e..e247e66 100644
--- a/gcc/ada/sem_ch3.adb
+++ b/gcc/ada/sem_ch3.adb
@@ -3154,7 +3154,7 @@ package body Sem_Ch3 is
while Present (X) loop
C := Etype (X);
- if not Is_Static_Subtype (C) then
+ if not Is_OK_Static_Subtype (C) then
Check_Restriction (Max_Tasks, N);
return Uint_0;
else
@@ -17370,7 +17370,7 @@ package body Sem_Ch3 is
-- static, even if its bounds are static.
if Nkind (I) = N_Subtype_Indication
- and then not Is_Static_Subtype (Entity (Subtype_Mark (I)))
+ and then not Is_OK_Static_Subtype (Entity (Subtype_Mark (I)))
then
Set_Is_Non_Static_Subtype (Def_Id);
end if;
@@ -18984,7 +18984,7 @@ package body Sem_Ch3 is
-- discrete type definition of a loop parameter specification.
if not In_Iter_Schm
- and then not Is_Static_Range (R)
+ and then not Is_OK_Static_Range (R)
then
Check_SPARK_Restriction ("range should be static", R);
end if;