Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 24 Jun 2005 13:14:45 -0300
From:      Cesar Mello <cmello@gmail.com>
To:        Erich Dollansky <oceanare@pacific.net.sg>
Cc:        Ryan Sommers <ryans@gamersimpact.com>, hackers@freebsd.org
Subject:   Re: To C++ or not to C++
Message-ID:  <c0ee48c5050624091462fcb4a2@mail.gmail.com>
In-Reply-To: <42BC248D.8060206@pacific.net.sg>
References:  <2140.66.166.104.222.1119623653.squirrel@66.166.104.222> <42BC248D.8060206@pacific.net.sg>

next in thread | previous in thread | raw e-mail | index | archive | help
Go for C++ and keep your C APIs hidden.=20
 Automatic resource acquisition, the standard template library and exceptio=
n=20
handling work great and will allow you to write very clean code.
 If you haven't done this yet, buy a copy of "The C++ Programming Language"=
=20
by Bjarne Stroustrup and "C++ Coding Standards" by Herb Sutter, that change=
d=20
my life drastically. hehe
 In the other hand, if you have seen MFC, forget everything you know as C++=
=20
and go buy those books.
 []
Mello


 2005/6/24, Erich Dollansky <oceanare@pacific.net.sg>:=20
>=20
> Hi,
>=20
> Ryan Sommers wrote:
> >
> > Anyway, without getting into too much detail. Anyone had to make this
> > choice on a project? What were your thoughts in retrospect? What would=
=20
> you
> > have done different, what would stay the same...
> >
> No matter what kind of project I did after the C++ hype was over it was
> in C++ with as little as object orientation as possible just to make use
> of the advantages compilers offer for C++.
>=20
> You need one or more interfaces to plain C libraries.
>=20
> You should see pretty fast where you better switch to C++ as long as you
> keep this clear line to C libraries always intact.
>=20
> You also should draw a clear line if your programs will be called from
> others. Draw the same clear line between C and C++ to avoid confusion
> and stick with plain C as much as possible.
>=20
> Never forget, many of the object orientated principles also work with
> plain C.
>=20
> Erich
> _______________________________________________
> freebsd-hackers@freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
> To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org=
"
>



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?c0ee48c5050624091462fcb4a2>