comp.lang.ada
 help / color / mirror / Atom feed
From: Maciej Sobczak <see.my.homepage@gmail.com>
Subject: Re: Overring function and its returned type
Date: Fri, 16 Nov 2012 07:27:37 -0800 (PST)
Date: 2012-11-16T07:27:37-08:00	[thread overview]
Message-ID: <8998c0eb-c9b1-4501-9163-94172aa4aea0@googlegroups.com> (raw)
In-Reply-To: <w--dnVaLevWLqTvNRVn_vwA@giganews.com>

W dniu piątek, 16 listopada 2012 13:39:50 UTC+1 użytkownik Peter C. Chapin napisał:

> Yet I wonder if 
> it increases the risk of an "unrelated" change breaking an existing code 
> base by introducing an ambiguity where none existed before.

I'm not sure - probably, today, it is too late to add this to the language for the reasons that you have mentioned. However, this feature could have been safely added together with other OO-related features, as the whole support for OO was new in the language and there was no existing codebase that would break.

An interesting property of Ada, and what makes this issue more difficult than in C++ is that Ada supports out parameters, which from the language design point of view should work like return values. Covariant return types are easy to picture, but covariant out parameters? Hm... Maybe this is where things would start to shake.

-- 
Maciej Sobczak * http://www.msobczak.com * http://www.inspirel.com



  reply	other threads:[~2012-11-16 15:27 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-11-09  7:13 Overring function and its returned type Yannick Duchêne (Hibou57)
2012-11-09  7:22 ` Yannick Duchêne (Hibou57)
2012-11-09  8:24 ` Dmitry A. Kazakov
2012-11-09  9:14   ` Yannick Duchêne (Hibou57)
2012-11-09 13:11     ` Dmitry A. Kazakov
2012-11-09 21:36       ` Yannick Duchêne (Hibou57)
2012-11-09 19:24   ` Adam Beneschan
2012-11-09 19:34 ` Adam Beneschan
2012-11-09 22:00   ` J-P. Rosen
2012-11-09 22:30     ` Yannick Duchêne (Hibou57)
2012-11-09 19:57 ` sbelmont700
2012-11-09 21:10   ` Yannick Duchêne (Hibou57)
2012-11-09 21:56     ` sbelmont700
2012-11-10  0:28     ` Yannick Duchêne (Hibou57)
2012-11-10  2:35       ` Yannick Duchêne (Hibou57)
2012-11-15 15:13   ` Peter C. Chapin
2012-11-16 10:40     ` Maciej Sobczak
2012-11-16 12:39       ` Peter C. Chapin
2012-11-16 15:27         ` Maciej Sobczak [this message]
2012-11-16 17:29           ` Peter C. Chapin
2012-11-17  4:16           ` Yannick Duchêne (Hibou57)
2012-11-17 19:11             ` Robert A Duff
2012-11-18 14:53               ` AdaMagica
2012-11-19  8:41                 ` Yannick Duchêne (Hibou57)
2012-11-19 13:04                   ` AdaMagica
2012-11-19 15:19                     ` Dmitry A. Kazakov
2012-11-19 23:42                   ` Randy Brukardt
2012-11-10  7:55 ` Randy Brukardt
2012-11-11  1:02   ` Yannick Duchêne (Hibou57)
replies disabled

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