comp.lang.ada
 help / color / mirror / Atom feed
From: "G.B." <bauhaus@futureapps.invalid>
Subject: Re: Surprising behaviour of strings.fixed.overwrite
Date: Wed, 12 Nov 2014 13:55:41 +0100
Date: 2014-11-12T13:55:41+01:00	[thread overview]
Message-ID: <m3vlc0$lb2$1@dont-email.me> (raw)
In-Reply-To: <m3vdvn$uu$1@speranza.aioe.org>

On 12.11.14 11:49, Markus Schöpflin wrote:
>
>
> Well, I would have expected the output to be
>
> @@@@@6
> @@@@@5
>
> But it is:
>
> @@@@56
> @@@@@5
>
> Which is correct according to the definition of overwrite, but
> nevertheless I find this extremely surprising.
>
> Am I alone in this?

No, I don't think so. To me it seems that perhaps the LRM is
trying to convey mathematical meaning using common sense words:
Overwrite involves creating a potentially longer string and
then dropping characters from that new string, either left
or right. In doing so, the procedure needs to abstractly
overwrite at positions before Position, which is odd.

  reply	other threads:[~2014-11-12 12:55 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-11-12 10:49 Surprising behaviour of strings.fixed.overwrite Markus Schöpflin
2014-11-12 12:55 ` G.B. [this message]
2014-11-12 15:49 ` Adam Beneschan
2014-11-12 23:19 ` Randy Brukardt
2014-11-13  8:15   ` Markus Schöpflin
2014-11-13 12:40     ` Simon Wright
2014-11-13 12:56       ` Markus Schöpflin
replies disabled

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