summaryrefslogtreecommitdiff
path: root/gcc/ada/sem_ch7.adb
diff options
context:
space:
mode:
authorcharlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4>2006-02-15 09:37:10 +0000
committercharlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4>2006-02-15 09:37:10 +0000
commit7778530cd163864f742e0a3a3e2cd484a8d0ce97 (patch)
tree2466e63ba49637bfbc14d86f34bd4a00ef77ddd1 /gcc/ada/sem_ch7.adb
parent2e12de5fb7f7fb80195981c934bd58fdf2f3cd28 (diff)
downloadgcc-7778530cd163864f742e0a3a3e2cd484a8d0ce97.tar.gz
2006-02-13 Javier Miranda <miranda@adacore.com>
Robert Dewar <dewar@adacore.com> Ed Schonberg <schonberg@adacore.com> * einfo.ads, einfo.adb (First_Tag_Component): Protect the frontend against errors in the source program: a private types for which the corresponding full type declaration is missing and pragma CPP_Virtual is used. (Is_Unchecked_Union): Check flag on Implementation_Base_Type. (Is_Known_Null): New flag (Has_Pragma_Pure): New flag (No_Return): Present in all entities, set only for procedures (Is_Limited_Type): A type whose ancestor is an interface is limited if explicitly declared limited. (DT_Offset_To_Top_Func): New attribute that is present in E_Component entities. Only used for component marked Is_Tag. If present it stores the Offset_To_Top function used to provide this value in tagged types whose ancestor has discriminants. * exp_ch2.adb: Update status of new Is_Known_Null flag * sem_ch7.adb: Maintain status of new Is_Known_Null flag * sem_cat.adb (Get_Categorization): Don't treat function as Pure in the categorization sense if Is_Pure was set by pragma Pure_Function. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@111055 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/ada/sem_ch7.adb')
-rw-r--r--gcc/ada/sem_ch7.adb8
1 files changed, 6 insertions, 2 deletions
diff --git a/gcc/ada/sem_ch7.adb b/gcc/ada/sem_ch7.adb
index e538970b5a4..77d28720673 100644
--- a/gcc/ada/sem_ch7.adb
+++ b/gcc/ada/sem_ch7.adb
@@ -6,7 +6,7 @@
-- --
-- B o d y --
-- --
--- Copyright (C) 1992-2005, Free Software Foundation, Inc. --
+-- Copyright (C) 1992-2006, 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- --
@@ -746,7 +746,11 @@ package body Sem_Ch7 is
Set_Never_Set_In_Source (E, False);
Set_Is_True_Constant (E, False);
Set_Current_Value (E, Empty);
- Set_Is_Known_Non_Null (E, False);
+ Set_Is_Known_Null (E, False);
+
+ if not Can_Never_Be_Null (E) then
+ Set_Is_Known_Non_Null (E, False);
+ end if;
elsif Ekind (E) = E_Package
or else