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=unavailable autolearn_force=no version=3.4.4 Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!news.eternal-september.org!news.eternal-september.org!feeder.eternal-september.org!aioe.org!.POSTED!not-for-mail From: "Dmitry A. Kazakov" Newsgroups: comp.lang.ada Subject: Re: Community Input for the Maintenance and Revision of the Ada Programming Language Date: Wed, 9 Aug 2017 20:49:51 +0200 Organization: Aioe.org NNTP Server Message-ID: References: <688bf053-8438-4189-be34-28ecfe53cf6e@googlegroups.com> NNTP-Posting-Host: MajGvm9MbNtGBKE7r8NgYA.user.gioia.aioe.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit X-Complaints-To: abuse@aioe.org User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.2.1 X-Notice: Filtered by postfilter v. 0.8.2 Content-Language: en-US Xref: news.eternal-september.org comp.lang.ada:47661 Date: 2017-08-09T20:49:51+02:00 List-Id: On 2017-08-09 19:23, Shark8 wrote: > On Wednesday, August 9, 2017 at 9:24:40 AM UTC-6, Johan Söderlind Åström wrote: >> I want the next version to include GNAT attributes. >> The X'Range_Length has been useful for me instead of writing (X'Last - X'First + 1) > > If we had first-class ranges we could do X'Range'Legth... True but that immediately brings a more general issue of related types up: - Element - Index - Index set (range) - Tuple of indices (flat index within n-D array) - Tuples set (indices indicating elements in an n-D array) - Array - Slice - Subarray (plane, row, column) - Elements set (diagonals) - Co-array (e.g. transponse) This, again, is all about empowering the type system. -- Regards, Dmitry A. Kazakov http://www.dmitry-kazakov.de