[Mono-list] C++ compatible CLR?

yoros@wanadoo.es yoros@wanadoo.es
Mon, 16 Dec 2002 23:55:01 +0100

Content-Type: text/plain; charset=iso-8859-1
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Mon, Dec 16, 2002 at 03:39:52PM -0500, Miguel de Icaza wrote:
> Hello,
> > Yesterday I have read an ca 1 years old article about .net again.
> >=20
> > In this magazine there stood advantages and disadvantages of C# and .ne=
> > (and things, what could be better) .
> >=20
> > Some of the things, which the magazine have listed, what could be bette=
r is,=20
> > that the CIL is not compatible to C++.
> > Not all C++-programs can be compiled to the CIL. The reason is, that C+=
> > supports "Mehrfachvererbung" for example - the CIL dosen't.
> > ("Mehrfachvererbung" is a german word. And I don't know how it is calle=
d in=20
> > english. Is it called "multi-heredity" ?)
> >=20
> > So, is it possible, that Mono integrate this features in its CIL, which=
> > Microsoft haven't integrated?
> Multiple-inheritance can be emulated on the CIL (C++ does this) and
> Eiffel.NET found an interesting trick to implement it, so there is no
> need to change the CIL.
> Now, even in that case, I am more interested in remaining compatible to
> the Microsoft CIL than to do our own extensions.
> But I am not shutting down your idea.  In fact, if someone is motivated
> enough, they can use Mono as a research platform to try out the idea, do
> a proof-of-concept implementation, and then they could propose this to
> the ECMA standards body.
> I do not know enough about multiple-inheritance to have a strong
> opinion, but I know people who do have a pretty strong opinion against
> it, so you might want to address those issues as well.
> > But for completeness, here the "disadvantages" of C#, which there was=
> > listed:
> > - it is not possible to get more parameters by one function back
> You can use `out' parameters.
> > - no support for definitions of pre- and postconditions and invariants.
> Brian posted a link yesterday about pre-conditions using attributes
> which was interesting.  It is not natively supported as Eiffel does.

I think that either the multiple inheritance and the design by contract
(preconditions, postconditions, invariants in all bodies (class, method,
loop, etc...)) are very useful. The multiple inheritance is also a great
advantage, not only for the implementation but for the object oriented
design too. At the end, I think that preconditions, postconditions,
invariants, etc... can be implemented with a few methods that can check
that all of that (classes, methods, etc...) are consistent.

See you,

Pedro Martinez Juli=E1
\  yoros@terra.es
)|    yoros@wanadoo.es
/        http://yoros.cjb.net
Socio HispaLinux #311
Usuario Linux #275438 - http://counter.li.org
GnuPG public information:  pub  1024D/74F1D3AC
Key fingerprint =3D 8431 7B47 D2B4 5A46 5F8E  534F 588B E285 74F1 D3AC

Content-Type: application/pgp-signature
Content-Disposition: inline

Version: GnuPG v1.2.1 (GNU/Linux)