From: "Yannick Duchêne (Hibou57)" <yannick_duchene@yahoo.fr>
Subject: Re: Generics vs. O-O?
Date: Sat, 03 Aug 2013 02:04:52 +0200
Date: 2013-08-03T02:04:52+02:00 [thread overview]
Message-ID: <op.w07rueppule2fv@cardamome> (raw)
In-Reply-To: 15qso6tlt3uf1.h45wqc019b00$.dlg@40tude.net
Le Fri, 02 Aug 2013 10:11:32 +0200, Dmitry A. Kazakov
<mailbox@dmitry-kazakov.de> a écrit:
> Here substitutability encompasses all parameters generics take, not just
> types. E.g.
>
> generic
> with function Foo (X : Integer) return Real;
> package Bar is ...
>
> You cannot verify if Baz
>
> function Baz (X : Integer) return Real;
>
> were substitutable in Bar for Foo.
I agree with this. Ability to require constraints on type parameters is
missing. As an example, I wish I could state it must have some
representation set on some value, or require some preconditions and
postconditions.
--
“Syntactic sugar causes cancer of the semi-colons.” [1]
“Structured Programming supports the law of the excluded muddle.” [1]
[1]: Epigrams on Programming — Alan J. — P. Yale University
next prev parent reply other threads:[~2013-08-03 0:04 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-08-01 14:45 Generics vs. O-O? Eryndlia Mavourneen
2013-08-01 19:24 ` Dmitry A. Kazakov
2013-08-01 19:52 ` Eryndlia Mavourneen
2013-08-01 20:14 ` sbelmont700
2013-08-01 23:35 ` Yannick Duchêne (Hibou57)
2013-08-01 20:10 ` optikos
2013-08-01 20:26 ` Dmitry A. Kazakov
2013-08-01 20:35 ` Jeffrey Carter
2013-08-01 21:22 ` Bill Findlay
2013-08-01 23:38 ` Yannick Duchêne (Hibou57)
2013-08-01 22:20 ` Georg Bauhaus
2013-08-02 8:11 ` Dmitry A. Kazakov
2013-08-02 9:50 ` Georg Bauhaus
2013-08-02 14:09 ` Dmitry A. Kazakov
2013-08-02 15:08 ` Shark8
2013-08-02 15:36 ` Alan Jump
2013-08-02 17:00 ` Jeffrey Carter
2013-08-02 17:51 ` Dmitry A. Kazakov
2013-08-02 18:06 ` Alan Jump
2013-08-02 19:08 ` Dmitry A. Kazakov
2013-08-02 16:15 ` Dmitry A. Kazakov
2013-08-03 0:04 ` Yannick Duchêne (Hibou57) [this message]
2013-08-03 7:35 ` Georg Bauhaus
2013-08-03 8:57 ` 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