diff options
author | Arnaud Charlet <charlet@gcc.gnu.org> | 2009-04-20 15:32:11 +0200 |
---|---|---|
committer | Arnaud Charlet <charlet@gcc.gnu.org> | 2009-04-20 15:32:11 +0200 |
commit | 37951d8ec681d06d6179bf78f5c8b88026454a64 (patch) | |
tree | d59ec9a86635f4416e38feca4a87bc29293a8eb2 | |
parent | 5d5832bc7e9f9712490733aa5207576fffd53528 (diff) | |
download | gcc-37951d8ec681d06d6179bf78f5c8b88026454a64.zip gcc-37951d8ec681d06d6179bf78f5c8b88026454a64.tar.gz gcc-37951d8ec681d06d6179bf78f5c8b88026454a64.tar.bz2 |
[multiple changes]
2009-04-20 Robert Dewar <dewar@adacore.com>
* checks.ads: Fix documentation of range check handling
2009-04-20 Ed Schonberg <schonberg@adacore.com>
* sem_ch8.adb (Use_One_Type): Use proper entity on warning message for
a redundant use_type clause.
From-SVN: r146422
-rw-r--r-- | gcc/ada/ChangeLog | 9 | ||||
-rw-r--r-- | gcc/ada/checks.ads | 6 | ||||
-rw-r--r-- | gcc/ada/sem_ch8.adb | 8 |
3 files changed, 17 insertions, 6 deletions
diff --git a/gcc/ada/ChangeLog b/gcc/ada/ChangeLog index 05c5b29..e185a31 100644 --- a/gcc/ada/ChangeLog +++ b/gcc/ada/ChangeLog @@ -1,5 +1,14 @@ 2009-04-20 Robert Dewar <dewar@adacore.com> + * checks.ads: Fix documentation of range check handling + +2009-04-20 Ed Schonberg <schonberg@adacore.com> + + * sem_ch8.adb (Use_One_Type): Use proper entity on warning message for + a redundant use_type clause. + +2009-04-20 Robert Dewar <dewar@adacore.com> + * sem_attr.adb (Eval_Attribute, case Length): Catch more cases where this attribute can be evaluated at compile time. (Eval_Attribute, case Range_Length): Same improvement diff --git a/gcc/ada/checks.ads b/gcc/ada/checks.ads index e0cc54d..1acdab1 100644 --- a/gcc/ada/checks.ads +++ b/gcc/ada/checks.ads @@ -214,9 +214,11 @@ package Checks is -- Range checks are controlled by the Do_Range_Check flag. The front end -- is responsible for setting this flag in relevant nodes. Originally -- the back end generated all corresponding range checks. But later on - -- we decided to generate all range checks in the front end. We are now + -- we decided to generate many range checks in the front end. We are now -- in the transitional phase where some of these checks are still done - -- by the back end, but many are done by the front end. + -- by the back end, but many are done by the front end. It is possible + -- that in the future we might move all the checks to the front end. The + -- main remaining back end checks are for subscript checking. -- Overflow checks are similarly controlled by the Do_Overflow_Check flag. -- The difference here is that if back end overflow checks are inactive diff --git a/gcc/ada/sem_ch8.adb b/gcc/ada/sem_ch8.adb index 097da0c..ce31510 100644 --- a/gcc/ada/sem_ch8.adb +++ b/gcc/ada/sem_ch8.adb @@ -7396,7 +7396,7 @@ package body Sem_Ch8 is else Error_Msg_NE ("& is already use-visible through previous " - & "use type clause?", Id, Id); + & "use type clause?", Id, T); end if; end Use_Clause_Known; @@ -7406,7 +7406,7 @@ package body Sem_Ch8 is else Error_Msg_NE ("& is already use-visible through previous " - & "use type clause?", Id, Id); + & "use type clause?", Id, T); end if; -- The package where T is declared is already used @@ -7415,14 +7415,14 @@ package body Sem_Ch8 is Error_Msg_Sloc := Sloc (Current_Use_Clause (Scope (T))); Error_Msg_NE ("& is already use-visible through package use clause #?", - Id, Id); + Id, T); -- The current scope is the package where T is declared else Error_Msg_Node_2 := Scope (T); Error_Msg_NE - ("& is already use-visible inside package &?", Id, Id); + ("& is already use-visible inside package &?", Id, T); end if; end if; end Use_One_Type; |