comp.lang.ada
 help / color / mirror / Atom feed
From: dewar@gnat.com (Robert Dewar)
Subject: Re: Slices of 2d arrays?
Date: 24 Jul 2002 17:33:52 -0700
Date: 2002-07-25T00:33:52+00:00	[thread overview]
Message-ID: <5ee5b646.0207241633.6518ef31@posting.google.com> (raw)
In-Reply-To: ahmb67$jjb$1@news.uni-stuttgart.de

Peter Hermann <ica2ph@iris16.csv.ica.uni-stuttgart.de> wrote in message news:<ahmb67$jjb$1@news.uni-stuttgart.de>...
>    g(1   ,4   ) is of type character
>    g(1..1,4..5) is of type grid
>    g(1   ,4..5) is of type grid slice?
>    g(1..1,4   ) is of type grid slice?
>    and the n-dimensional arrays?
> 
> No.   Language designers will certainly refusei, IMHO.

It is not hard to work out the semantics of this feature,
just see Algol-68 for inspiration.

However, as soon as you extend slices to >1D arrays, the
feature no longer obeys the "Bauer Principle" which says
that you should not pay overhead for a feature unless
you use it. That's because general slicing results in
non-standard strides, and you have to allow for this
whether or not such slicing is used.



  reply	other threads:[~2002-07-25  0:33 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-07-24  9:29 Slices of 2d arrays? Dale Stanbrough
2002-07-24  9:39 ` Lutz Donnerhacke
2002-07-24 12:41   ` Pascal Obry
2002-07-25  0:38   ` Robert Dewar
2002-07-24 13:47 ` Peter Hermann
2002-07-25  0:33   ` Robert Dewar [this message]
2002-07-25 11:26     ` Slices of 2d arrays? +HPF Peter Hermann
2002-07-25 13:04       ` Jacob Sparre Andersen
2002-07-25 15:58         ` Darren New
2002-07-28 23:54           ` Robert Dewar
2002-07-25 20:31     ` Slices of 2d arrays? Robert A Duff
2002-07-25 21:09       ` Chad R. Meiners
2002-07-29 13:37         ` Robert Dewar
2002-07-29 14:08           ` Steffen Huber
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox