comp.lang.ada
 help / color / mirror / Atom feed
From: Adam Beneschan <adambeneschan@gmail.com>
Subject: Re: Suggestion: Allow functions returning abstract types in certain situations
Date: Wed, 21 May 2014 15:33:42 -0700 (PDT)
Date: 2014-05-21T15:33:42-07:00	[thread overview]
Message-ID: <06f66a19-00f1-405f-a517-05d18a021b65@googlegroups.com> (raw)
In-Reply-To: <wccsio2zt4a.fsf@shell01.TheWorld.com>

On Wednesday, May 21, 2014 3:04:05 PM UTC-7, Robert A Duff wrote:
> Adam Beneschan writes:

> >...In my view, the language model depends heavily on
> > the assumption that an object can never be created whose tag refers to
> > an abstract type; allowing the rule to *ever* be relaxed could be
> > disastrous.
> 
> I don't think so.  As I posted a while back, the only trouble comes
> from converting an object of an abstract type to a class-wide
> type -- that is what needs to be forbidden.

Hmmm... I'd worry that if we allowed an object with an abstract-type tag to exist even for a little while, something in the language semantics might require Initialize, Adjust, or Finalize to be called on it, which could be bad if, for example, it tried to redispatch to an abstract body.  (I don't remember the earlier conversation, so I don't know if this was dealt with already.)

                                  -- Adam

  reply	other threads:[~2014-05-21 22:33 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-05-21 14:52 Suggestion: Allow functions returning abstract types in certain situations Victor Porton
2014-05-21 16:10 ` Adam Beneschan
2014-05-21 19:09   ` Dan'l Miller
2014-05-21 22:09     ` Robert A Duff
2014-05-21 22:29       ` Adam Beneschan
2014-05-21 22:04   ` Robert A Duff
2014-05-21 22:33     ` Adam Beneschan [this message]
2014-05-21 23:19       ` Robert A Duff
2014-05-22  7:22         ` Dmitry A. Kazakov
2014-05-24 18:39           ` Robert A Duff
2014-05-24 19:20             ` Dmitry A. Kazakov
2014-05-22 14:47         ` Adam Beneschan
2014-05-24 18:45           ` Robert A Duff
replies disabled

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