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: 103376,789720372441e329 X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news2.google.com!proxad.net!news.tele.dk!news.tele.dk!small.news.tele.dk!news-fra1.dfn.de!news-ham1.dfn.de!news.zfn.uni-bremen.de!informatik.uni-bremen.de!cs.tu-berlin.de!uni-duisburg.de!not-for-mail From: Georg Bauhaus Newsgroups: comp.lang.ada Subject: Re: What exactly is a 'record' in Ada 95? Date: Wed, 8 Sep 2004 13:40:15 +0000 (UTC) Organization: GMUGHDU Message-ID: References: NNTP-Posting-Host: l1-hrz.uni-duisburg.de X-Trace: a1-hrz.uni-duisburg.de 1094650815 18080 134.91.1.34 (8 Sep 2004 13:40:15 GMT) X-Complaints-To: usenet@news.uni-duisburg.de NNTP-Posting-Date: Wed, 8 Sep 2004 13:40:15 +0000 (UTC) User-Agent: tin/1.5.8-20010221 ("Blue Water") (UNIX) (HP-UX/B.11.00 (9000/800)) Xref: g2news1.google.com comp.lang.ada:3483 Date: 2004-09-08T13:40:15+00:00 List-Id: matthias_k wrote: : So, what is a 'record' in Ada? Do I have to think about it like : a struct in C? It seems to serve the same purpose. Is 'record' the : only type modifier? Where are the differences? For values of a record type, there are useful notations. For example, a two component record value might be written as (name => "Frank", age => 56) or alternatively (age => 56, name => "Frank") or alternatively Person'(name => "Frank", age = 56) or altenatively Person'("Frank", 56) or just ("Frank", 56) I'll leave it to you to find out what other alternatives there are, if any. In any case the compiler will check that _all_ record components get values. -- Georg