This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug ada/36777] New: Protected type cannot have access taken from its body.
- From: "prog at msobczak dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 9 Jul 2008 21:18:15 -0000
- Subject: [Bug ada/36777] New: Protected type cannot have access taken from its body.
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
Protected type cannot have access taken from its body.
The following should work:
protected type P is
procedure Foo;
end P;
protected body P is
procedure Foo is
Ptr : access P; -- here P denotes the type P
begin
Ptr := P'Access; -- here P denotes the "this" instance of P
end;
end P;
The compiler complains that 'Access cannot be applied to a type, which is in
conflict with AARM 9.4-21/2.
--
Summary: Protected type cannot have access taken from its body.
Product: gcc
Version: 4.4.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: ada
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: prog at msobczak dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36777