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.4 required=5.0 tests=AC_FROM_MANY_DOTS,BAYES_00, XPRIO autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,cb68a222818235ed,start X-Google-Attributes: gid103376,public Path: g2news1.google.com!news1.google.com!news.glorb.com!cyclone1.gnilink.net!gnilink.net!newsfeed.news2me.com!Spring.edu.tw!news.nctu.edu.tw!feeder.seed.net.tw!attdv1!ip.att.net!newsfeed1.global.lmco.com!svlnews.lmms.lmco.com!not-for-mail From: "Xenos" Newsgroups: comp.lang.ada Subject: Renaming of enumeration constant Date: Thu, 10 Jun 2004 11:37:44 -0400 Organization: Hades Message-ID: NNTP-Posting-Host: 158.187.64.144 X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2800.1409 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1409 Xref: g2news1.google.com comp.lang.ada:1370 Date: 2004-06-10T11:37:44-04:00 List-Id: Just a curiosity question: What is the difference (advantages, etc.) of defining a function rename for an enumeration constant over just creating a constant. Consider: package X is type E is (A, B, C); end X; with X; package Y is function A return X.E renames X.A; end Y; with X; package Z is A : constant X.E := X.A; end Z; Is the "A" in Y treated any different than the "A" in Z by the compiler, or will both achieve the same results. Is one considered "better" (whatever that means) than the other? Thanks, DrX