aboutsummaryrefslogtreecommitdiff
path: root/gcc/ada/lib-xref-alfa.adb
diff options
context:
space:
mode:
authorArnaud Charlet <charlet@gcc.gnu.org>2011-09-05 14:58:26 +0200
committerArnaud Charlet <charlet@gcc.gnu.org>2011-09-05 14:58:26 +0200
commit7109f4f52da4ea189b04aeb29a077d140855cb52 (patch)
tree066827c96ac7d0b966728b9e27ebe3f6ed3cef82 /gcc/ada/lib-xref-alfa.adb
parent66dc8075f33117924fc1596721708e979912e20e (diff)
downloadgcc-7109f4f52da4ea189b04aeb29a077d140855cb52.zip
gcc-7109f4f52da4ea189b04aeb29a077d140855cb52.tar.gz
gcc-7109f4f52da4ea189b04aeb29a077d140855cb52.tar.bz2
[multiple changes]
2011-09-05 Bob Duff <duff@adacore.com> * sem_res.adb (Resolve_Intrinsic_Operator): Use unchecked conversions instead of normal type conversions in all cases where a type conversion would be illegal. In particular, use unchecked conversions when the operand types are private. 2011-09-05 Johannes Kanig <kanig@adacore.com> * lib-xref-alfa.adb (Is_Alfa_Reference): Never declare effects on objects of task type or protected type. From-SVN: r178531
Diffstat (limited to 'gcc/ada/lib-xref-alfa.adb')
-rw-r--r--gcc/ada/lib-xref-alfa.adb15
1 files changed, 15 insertions, 0 deletions
diff --git a/gcc/ada/lib-xref-alfa.adb b/gcc/ada/lib-xref-alfa.adb
index ce95463..a2ea0e6 100644
--- a/gcc/ada/lib-xref-alfa.adb
+++ b/gcc/ada/lib-xref-alfa.adb
@@ -620,7 +620,22 @@ package body Alfa is
return False;
when others =>
+
+ -- Objects of Task type or protected type are not Alfa
+ -- references.
+
+ if Present (Etype (E)) then
+ case Ekind (Etype (E)) is
+ when E_Task_Type | E_Protected_Type =>
+ return False;
+
+ when others =>
+ null;
+ end case;
+ end if;
+
return Typ = 'r' or else Typ = 'm';
+
end case;
end Is_Alfa_Reference;