comp.lang.ada
 help / color / mirror / Atom feed
From: "Dmitry A. Kazakov" <mailbox@dmitry-kazakov.de>
Subject: Re: limited types (Was: Records that could be arrays)
Date: Sat, 25 Feb 2006 12:06:20 +0100
Date: 2006-02-25T12:06:12+01:00	[thread overview]
Message-ID: <asr2qwci95ux.1qadozdgntmnv$.dlg@40tude.net> (raw)
In-Reply-To: BfCdnQZCaeilHWLenZ2dnUVZ_vmdnZ2d@megapath.net

On Fri, 24 Feb 2006 15:57:46 -0600, Randy Brukardt wrote:

> Indeed, many of us think that "limited" should be the default for Ada. (It
> certainly ought to be for interfaces and tagged types, because that allows
> more uses.) Only if you *need* assignment should something be non-limited.

Right
 
> Of course, you often do need assignment. The containers are non-limited so
> that they can be composed. And that's because it doesn't make sense to have
> limited elements (as the elements have to be copied into the container).

I think that there should also be [limited] containers of limited types.
For this we need a construction model, which would allow user-defined
in-place constructors. After all Ada has always had arrays of limited
components. We have to extend this model onto user-defined containers.

I think that this would require separation of assignment from copy
constructor, as C++ does. Though the default must be that assignment is
generated from destructor and copy constructor.

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



  parent reply	other threads:[~2006-02-25 11:06 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-02-24 16:51 limited types (Was: Records that could be arrays) Thierry Bernier
2006-02-24 21:57 ` Randy Brukardt
2006-02-25  2:21   ` Matthew Heaney
2006-02-25  3:38     ` Matthew Heaney
2006-02-25 11:06   ` Dmitry A. Kazakov [this message]
2006-02-25 15:05     ` Matthew Heaney
2006-02-26  1:01       ` Randy Brukardt
2006-02-26  9:00       ` Dmitry A. Kazakov
2006-02-26 18:20         ` Matthew Heaney
2006-02-26 20:52           ` Dmitry A. Kazakov
2006-02-26 22:07             ` Matthew Heaney
2006-02-27  9:11               ` Dmitry A. Kazakov
2006-02-27 14:34                 ` Georg Bauhaus
2006-02-27 16:05                   ` Dmitry A. Kazakov
2006-02-27 16:52                     ` Matthew Heaney
2006-02-27 20:21                       ` Dmitry A. Kazakov
2006-02-27 21:40                         ` Georg Bauhaus
2006-02-28  9:38                           ` Dmitry A. Kazakov
2006-02-27 23:00                         ` Matthew Heaney
2006-02-28  9:39                           ` Dmitry A. Kazakov
2006-02-28 17:24                             ` Matthew Heaney
2006-02-28 19:06                               ` Dmitry A. Kazakov
2006-02-28 19:58                                 ` Matthew Heaney
2006-02-28 21:03                                   ` Dmitry A. Kazakov
2006-02-28 21:51                                   ` limited types Simon Wright
2006-03-01  1:59                                     ` Matthew Heaney
replies disabled

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