comp.lang.ada
 help / color / mirror / Atom feed
From: Adam Beneschan <adam@irvine.com>
Subject: Re: Bug or feature: representation makes aliasing with renaming declaration an error
Date: Wed, 20 Jun 2012 13:45:28 -0700 (PDT)
Date: 2012-06-20T13:45:28-07:00	[thread overview]
Message-ID: <c58580ab-a38b-4256-a021-ecb6381ada06@googlegroups.com> (raw)
In-Reply-To: <4fe22876$0$9510$9b4e6d93@newsspool1.arcor-online.net>

On Wednesday, June 20, 2012 12:46:09 PM UTC-7, Georg Bauhaus wrote:
> Hi,
> 
> Compiling: aliasing.ads (source file time stamp: 2012-06-20 19:41:48)
> 
>       1. package Aliasing is
>       2.
>       3.    type I is ('a', 'b', 'c');
>       4.    for I use (11, 22, 33);              --!
>       5.
>       6.    type T is range 1 .. 10;
>       7.    type Ary is array (I) of aliased T;
>       8.    type Ptr is access constant T;
>       9.
>      10.    Vs : Ary;
>      11.    Nm : T renames Vs('b');
>      12.    X : Ptr := Nm'Access;
>                        |
>          >>> prefix of "Access" attribute must be aliased
> 
>      13.
>      14. end Aliasing;
> 
>   14 lines: 1 error
> 
> The error goes away when line 4 is commented.
> Is this expected behavior or is my compiler confused?

This appears to be a compiler bug.

                            -- Adam



  reply	other threads:[~2012-06-20 20:46 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-06-20 19:46 Bug or feature: representation makes aliasing with renaming declaration an error Georg Bauhaus
2012-06-20 20:45 ` Adam Beneschan [this message]
2012-06-21 20:51   ` Georg Bauhaus
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox