[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: (OT) Re: memory management
Borko Jandras wrote:
> I would say that the opinion goes that any PL other than C should be avoided
> for SDKs just because it is not C. Nothing about C++ or OO. This is IMHO a
> valid point and a point I'm behind 100%. Is C heaven sent? No. Should C be
> replaced by something better? Yes. Is C++ that thing? Absolutely NO! Does that
> thing exist right now? No.
The other problem with C++ as a language for specifying API's is that
you
have to expose lots of implementation details in the header file...and
it's
also frighteningly easy to break existing binaries when you do a library
update.
This is a serious problem for OS API's - but less so for higher level
API's
and things that are more application-specific.
(Dragging things back on topic here)
So, I feel somewhat justified in writing ALL my interfaces in C++
because
it greatly simplifies coding compared to C...but if I were writing
somewhat
lower level API's, I'd (reluctantly) use C.
--
Steve Baker http://web2.airmail.net/sjbaker1
sjbaker1@airmail.net (home) http://www.woodsoup.org/~sbaker
sjbaker@hti.com (work)