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=-0.9 required=5.0 tests=BAYES_00,FORGED_GMAIL_RCVD, FREEMAIL_FROM autolearn=no autolearn_force=no version=3.4.4 X-Google-Thread: a07f3367d7,c689b55786a9f2bd X-Google-Attributes: gida07f3367d7,public,usenet X-Google-NewGroupId: yes X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news2.google.com!news3.google.com!feeder.news-service.com!newsfeed.straub-nv.de!eternal-september.org!.POSTED!not-for-mail From: Warren Newsgroups: comp.lang.ada Subject: Re: for S'Image use Func?? Date: Thu, 6 May 2010 19:50:21 +0000 (UTC) Organization: A noiseless patient Spider Message-ID: References: Injection-Date: Thu, 6 May 2010 19:50:21 +0000 (UTC) Injection-Info: mx02.eternal-september.org; posting-host="9f8M0iN5t54V+4DF/iqO8g"; logging-data="7347"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/6Gb2H0yPPisbI7UGIR6Duomj6NYiNAaQ=" User-Agent: Xnews/5.04.25 X-Face: &6@]C2>ZS=NM|HE-^zWuryN#Z/2_.s9E|G&~DRi|sav9{E}XQJb*\_>=a5"q]\%A;5}LKP][1mA{gZ,Q!j Cancel-Lock: sha1:XgXPfn/QM8bhUJLBYgFhXJmAQ4s= Xref: g2news2.google.com comp.lang.ada:11335 Date: 2010-05-06T19:50:21+00:00 List-Id: Jeffrey R. Carter expounded in news:hrv32p$nnu$1@tornado.tornevall.net: > Warren wrote: >> >> type LNumber_Type is range 0..99_999; >> >> Can I declare.. >> >> for LNumber_Type'Image use LNumber_To_String; > > No. Nor can I see why you'd want to. Once you declare > > function Image (Value : Lnumber_Type) return String; > > why would you want to write > > Lnumber_Type'Image (I) > > rather than > > Image (I) > > ? I agree that it is indeed clumsier. It's just that I tend to use it a lot in debug output, rather than chasing down the package prefix for the To_String() function. I know I can always get away with: Put_Line("The value V=" & T'Image(V)); But everyone has convinced me that it is not a good practice, even if it were allowed. :) Warren