comp.lang.ada
 help / color / mirror / Atom feed
* Bug or feature: representation makes aliasing with renaming declaration an error
@ 2012-06-20 19:46 Georg Bauhaus
  2012-06-20 20:45 ` Adam Beneschan
  0 siblings, 1 reply; 3+ messages in thread
From: Georg Bauhaus @ 2012-06-20 19:46 UTC (permalink / raw)


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?



^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2012-06-21 20:51 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
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
2012-06-21 20:51   ` Georg Bauhaus

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