aboutsummaryrefslogtreecommitdiff
path: root/gcc/ada/freeze.adb
diff options
context:
space:
mode:
authorArnaud Charlet <charlet@gcc.gnu.org>2012-04-26 11:44:01 +0200
committerArnaud Charlet <charlet@gcc.gnu.org>2012-04-26 11:44:01 +0200
commit50cd5b4de92b3c4616e4ee567f7ad7bcec068f18 (patch)
treedb5a7bbfe11d0e117ba306db000ae772a5fbd187 /gcc/ada/freeze.adb
parent851634c76df50c39045cfa3f2aabe02d7ad5203b (diff)
downloadgcc-50cd5b4de92b3c4616e4ee567f7ad7bcec068f18.zip
gcc-50cd5b4de92b3c4616e4ee567f7ad7bcec068f18.tar.gz
gcc-50cd5b4de92b3c4616e4ee567f7ad7bcec068f18.tar.bz2
[multiple changes]
2012-04-26 Robert Dewar <dewar@adacore.com> * sem_util.adb: Minor reformatting. 2012-04-26 Thomas Quinot <quinot@adacore.com> * exp_aggr.adb, exp_pakd.adb (Setup_Inline_Packed_Array_Reference, Packed_Array_Aggregate_Handled.Get_Component_Val): Reverse bit numbering within PAT when Reverse_Storage_Order applies to the enclosing record. 2012-04-26 Thomas Quinot <quinot@adacore.com> * freeze.adb (Freeze_Record_Type): Improve error message for Scalar_Storage_Order inconsistent with Bit_Order. From-SVN: r186865
Diffstat (limited to 'gcc/ada/freeze.adb')
-rw-r--r--gcc/ada/freeze.adb16
1 files changed, 7 insertions, 9 deletions
diff --git a/gcc/ada/freeze.adb b/gcc/ada/freeze.adb
index 3eae40e..5a7d3b2 100644
--- a/gcc/ada/freeze.adb
+++ b/gcc/ada/freeze.adb
@@ -2138,15 +2138,13 @@ package body Freeze is
if Present (ADC)
and then Reverse_Bit_Order (Rec) /= Reverse_Storage_Order (Rec)
then
- if Bytes_Big_Endian = not Reverse_Storage_Order (Rec) then
- Error_Msg_N
- ("Scalar_Storage_Order High_Order_First is inconsistent with"
- & " Bit_Order", ADC);
- else
- Error_Msg_N
- ("Scalar_Storage_Order Low_Order_First is inconsistent with"
- & " Bit_Order", ADC);
- end if;
+ -- Note: report error on Rec, not on ADC, as ADC may apply to
+ -- an ancestor type.
+
+ Error_Msg_Sloc := Sloc (ADC);
+ Error_Msg_N
+ ("scalar storage order for& specified# inconsistent with "
+ & "its bit order", Rec);
end if;
-- Deal with Bit_Order aspect specifying a non-default bit order