From: "Dmitry A. Kazakov" <mailbox@dmitry-kazakov.de>
Subject: Re: Redefining "in" "operator"
Date: Mon, 5 Feb 2018 18:23:52 +0100
Date: 2018-02-05T18:23:52+01:00 [thread overview]
Message-ID: <p5a3v8$ss0$1@gioia.aioe.org> (raw)
In-Reply-To: p5a0k1$9tk$1@dont-email.me
On 2018-02-05 17:26, Alejandro R. Mosteo wrote:
> Are there special reasons not to allow something like that? I think "in"
> is not an operator in the Ada RM sense but now I'm curious why the
> special treatment.
Because some arguments are not first class citizens.
> It's merely to avoid subversion of the default behavior? Couldn't it
> only be allowed for couples of types where it doesn't apply?
That depends on which "in" need to become a normal function.
1. Type types: if X in T'Class then
2. Sets: if I in A'Range then
3. Indicator sets: for I in A'Range loop
Only #1 is very difficult. #2 and #3 require some mental efforts and
willingness of ARG.
--
Regards,
Dmitry A. Kazakov
http://www.dmitry-kazakov.de
next prev parent reply other threads:[~2018-02-05 17:23 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-02-05 16:26 Redefining "in" "operator" Alejandro R. Mosteo
2018-02-05 16:39 ` Jeffrey R. Carter
2018-02-06 0:48 ` Randy Brukardt
2018-02-06 18:07 ` Jeffrey R. Carter
2018-02-05 16:43 ` J-P. Rosen
2018-02-05 17:23 ` Dmitry A. Kazakov [this message]
2018-02-05 17:41 ` Alejandro R. Mosteo
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox