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!news.glorb.com!news-in-01.newsfeed.easynews.com!easynews!core-easynews-01!easynews.com!en-nntp-07.dc1.easynews.com.POSTED!not-for-mail From: Rob Solomon Newsgroups: comp.lang.ada Subject: Re: put of access type Message-ID: References: X-Newsreader: Forte Agent 4.2/32.1118 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Complaints-To: abuse@easynews.com Organization: Forte Inc. http://www.forteinc.com/apn/ X-Complaints-Info: Please be sure to forward a copy of ALL headers otherwise we will be unable to process your complaint properly. Date: Tue, 18 Aug 2009 23:36:15 -0400 Xref: g2news2.google.com comp.lang.ada:7856 Date: 2009-08-18T23:36:15-04:00 List-Id: >Rob Solomon wrote: >> I would like to output a pointer to the screen. > >Why? An access value is not usually meaningful. > >In general, you can't do this. However, using an instantiation of >System.Address_To_Access_Conversions, you can convert values of the access type >Object_Pointer declared there to type System.Address. Then, using >System.Storage_Elements.To_Integer, you can convert that address to an integer >type that you can output using 'Image with Ada.Text_IO or an instantiation of >the appropriate generic from Ada.Text_IO. I thought someone would question why I want this. As I said in my 1st message, I'm trying to learn the language and I would like to see what happens when I define pointers. I mean access types. The only way I know to see the results of my playing is to output them. Thanks for the help, Rob