comp.lang.ada
 help / color / mirror / Atom feed
From: "Dmitry A. Kazakov" <mailbox@dmitry-kazakov.de>
Subject: Re: Proliferation of Reserved Words
Date: Wed, 2 Jun 2021 21:21:31 +0200	[thread overview]
Message-ID: <s98lno$ais$1@gioia.aioe.org> (raw)
In-Reply-To: 827c60f6-b008-468b-9ab4-cf110edff252n@googlegroups.com

On 2021-06-02 20:13, AdaMagica wrote:

> This discussion really is 40 years late. But entries and procedures are in fact very different beasts.
> A procedure is reentrant and has exactly one body.
> An entry is not reentrant and cannot be called recursively; it has no body, rather it may have as many accept statements as you like or feel necessary (it may even have none - what the heck!).

Yes, but I would argue that these are implementation details. It might 
have sense to consider them having same interface, as we do now, after 
the dot-notation was introduced. In Ada 83 it was not so.

> So different keywords for them are quite reasonable.

So long the implementation details leak, as we have no tagged tasks and 
protected objects and no multiple dispatch. Otherwise all calling 
notations could be made fully equivalent for all bodies.

> Thinking about this:
> Ultimatey, we could perhaps do with just one reserved word called keyword. Depending on the place where is stands makes it clear what it means:
> keyword I keyword 1..10 keyword
>    X(I) := I + 1;
> Keyword;

Yes, one needs only one pair of delimiters. It reminds me construction 
of Z in ZFS using sets:

    0 = Ø
    1 = {Ø}
    2 = {{Ø}}
    ...

Similarly the for-loop could be:

   (<index>, <from>, <to>, <body>)

-- 
Regards,
Dmitry A. Kazakov
http://www.dmitry-kazakov.de

  reply	other threads:[~2021-06-02 19:21 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-05-31 20:51 Proliferation of Reserved Words Jeffrey R. Carter
2021-05-31 21:27 ` Dmitry A. Kazakov
2021-06-01  5:54   ` Randy Brukardt
2021-06-01  7:40     ` Paul Rubin
2021-06-03  8:48       ` Robin Vowels
2021-06-01  9:51     ` Jeffrey R. Carter
2021-06-01 16:06     ` Simon Wright
2021-06-01 11:48 ` Luke A. Guest
2021-06-02 18:13   ` AdaMagica
2021-06-02 19:21     ` Dmitry A. Kazakov [this message]
2021-06-02 20:13       ` Chris Townley
2021-06-02 20:18     ` Jeffrey R. Carter
2021-06-02 23:23     ` Bill Findlay
2021-06-03 23:58     ` Keith Thompson
2021-06-04  6:58       ` Dmitry A. Kazakov
replies disabled

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