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-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,ae67f75abbc71211 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2002-02-24 17:49:03 PST Path: archiver1.google.com!news1.google.com!sn-xit-02!supernews.com!news.tele.dk!small.news.tele.dk!204.71.34.15!news-out.cwix.com!newsfeed.cwix.com!news.binc.net!kilgallen From: Kilgallen@SpamCop.net (Larry Kilgallen) Newsgroups: comp.lang.ada Subject: Re: Why not using [] instead of () for array? Date: 24 Feb 2002 19:48:54 -0600 Organization: LJK Software Message-ID: References: <9ff447f2.0202241719.446bf17b@posting.google.com> NNTP-Posting-Host: eisner.encompasserve.org X-Trace: grandcanyon.binc.net 1014601742 30767 192.135.80.34 (25 Feb 2002 01:49:02 GMT) X-Complaints-To: abuse@binc.net NNTP-Posting-Date: Mon, 25 Feb 2002 01:49:02 +0000 (UTC) Xref: archiver1.google.com comp.lang.ada:20341 Date: 2002-02-24T19:48:54-06:00 List-Id: In article <9ff447f2.0202241719.446bf17b@posting.google.com>, byhoe@greenlime.com (Adrian Hoe) writes: > "Why not use [] instead of () for array in Ada?" I thought I had heard that certain keyboard limitations affected the choice when Ada83 was being standardized. > Two reasons for [] is preferred to (): > > 1. More clarity, certainly leads to more readability. > > 2. More distinguishable from functions parameters and leads to 1. My understanding is that function parameters and array indices are intentionally encoded with the same bracketing types to allow one to be substituted for another in a subsequent version of a program. A function might be more efficient for a very sparse array, even though the logical construct is an array.