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=-2.9 required=5.0 tests=BAYES_00,MAILING_LIST_MULTI autolearn=unavailable autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,6e15e3f9aeb3d14a X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2001-08-20 14:58:55 PST Path: archiver1.google.com!newsfeed.google.com!sn-xit-02!supernews.com!news.tele.dk!small.news.tele.dk!213.56.195.71!fr.usenet-edu.net!usenet-edu.net!enst!enst.fr!not-for-mail From: "David C. Hoos" Newsgroups: comp.lang.ada Subject: Re: Anonymous array clarification.(Better idea, I think.) Date: Mon, 20 Aug 2001 16:58:29 -0500 Organization: ENST, France Sender: comp.lang.ada-admin@ada.eu.org Message-ID: References: Reply-To: comp.lang.ada@ada.eu.org NNTP-Posting-Host: marvin.enst.fr Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Trace: avanie.enst.fr 998344734 63235 137.194.161.2 (20 Aug 2001 21:58:54 GMT) X-Complaints-To: usenet@enst.fr NNTP-Posting-Date: Mon, 20 Aug 2001 21:58:54 +0000 (UTC) To: Return-Path: X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 5.50.4522.1200 X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4522.1200 Errors-To: comp.lang.ada-admin@ada.eu.org X-BeenThere: comp.lang.ada@ada.eu.org X-Mailman-Version: 2.0.4 Precedence: bulk List-Help: List-Post: List-Subscribe: , List-Id: comp.lang.ada mail<->news gateway List-Unsubscribe: , List-Archive: Errors-To: comp.lang.ada-admin@ada.eu.org X-BeenThere: comp.lang.ada@ada.eu.org Xref: archiver1.google.com comp.lang.ada:12150 Date: 2001-08-20T16:58:29-05:00 ----- Original Message ----- From: "McDoobie" Newsgroups: comp.lang.ada To: Sent: Monday, August 20, 2001 4:40 PM Subject: Re: Anonymous array clarification.(Better idea, I think.) > Okay, from the above posts in this thread, I think I might be getting > somewhere. > > I'm thinking my problem stems from understanding the difference between an > "Object" and a type. As I'm coming from a C background, Objects and > Classes are real fuzzy for me. > > So if I say... > > type foo_array is array(1..N) of character; > > this would be an Object declaration. Then I would instantiate it > thusly.... > > bar_array : foo_array; > > correct? > No. Bar_array is an object declaration. foo_array is a type declaration. > However if I say... > > some_chars : array(1..N) of character; > > this would be just a simple array declaration, with none of the Object > Oriented properties carried along with it. > some_chars is also an object declaration, but of an anonymous array type. > And with the Object "foo_array" declared above, I could say ... > > type Upper_Case is subtype foo_array; > > and it should work? There is nothing yet to"work," since there are no executable statements, only declarations. In fact, you have declared no object of type Upper_Case, so it does noting for you but to declare a type of which you have declared no object. None of whjat you've done so far has anything to do with the object-oriented features of Ada. It seems like you really need to get hold of a good Ada book. > > Am I beginning to get the picture? > > McDoobie > chris@dont.spam.me > _______________________________________________ > comp.lang.ada mailing list > comp.lang.ada@ada.eu.org > http://ada.eu.org/mailman/listinfo/comp.lang.ada >