From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: a07f3367d7,9506bdc34331969a X-Google-Attributes: gida07f3367d7,public,usenet X-Google-NewGroupId: yes X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news2.google.com!news2.google.com!npeer01.iad.highwinds-media.com!news.highwinds-media.com!feed-me.highwinds-media.com!post02.iad.highwinds-media.com!news.flashnewsgroups.com-b7.4zTQh5tI3A!not-for-mail Newsgroups: comp.lang.ada Subject: Re: put of access type References: From: Stephen Leake Date: Thu, 20 Aug 2009 04:05:51 -0400 Message-ID: User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.2 (windows-nt) Cancel-Lock: sha1:MJVZpIEnqkEqK9qBCmhKs34hn/c= MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Complaints-To: abuse@flashnewsgroups.com Organization: FlashNewsgroups.com X-Trace: 536d94a8d03cce197caa700300 Xref: g2news2.google.com comp.lang.ada:7900 Date: 2009-08-20T04:05:51-04:00 List-Id: Dennis Lee Bieber writes: > On Tue, 18 Aug 2009 23:36:15 -0400, Rob Solomon > declaimed the following in comp.lang.ada: > >> The only way I know to see the results of my playing is to output >> them. >> > And what meaning would some address from either the stack or a heap > have? You can't modify them -- Ada's access types are so heavily > controlled they are basically black boxes with no inherent meaning. Yes, but seeing the actual values helps the learning process. For example: A : aliased Interfaces.Unsigned_32; B : aliased Interfaces.Unsigned_32; begin Put (To_Integer (A'access)); Put (To_Integer (B'access)); The results should be 4 bytes apart. But doing the same with unconstrained arrays will show "extra" bytes being allocated; that's the array limits, also known as "dope". Another way to see the values of access types is in the debugger. -- -- Stephe