Linked by Eugenia Loli on Sun 16th Dec 2007 00:04 UTC, submitted by obsethryl
Gentoo A relatively lengthy Q&A with Ciaran McCreesh about Paludis, the Portage alternative for Gentoo.
Thread beginning with comment 291549
To view parent comment, click here.
To read all comments associated with this story, please click here.
RE[2]: was a long time gentoo fan...
by MORB on Mon 17th Dec 2007 10:22 UTC in reply to "RE: was a long time gentoo fan..."
Member since:

"Since when does C++ deliver reduced risk of buggy code slipping through when compared to, say, Python?"

The curse of C++ is to forever be judged negatively by people who have no idea what the language is about.

C++ is all about static typing and catching as many error as possible at compilation time (as in, many things that would not work or lead to bugs shouldn't compile).

Of course, since it's backward compatible with C it also provides many ways to force your bad code through and many unsafe legacy alternative ways to do things (pointer arithmetic, c-style arrays, managing strings as manually allocated byte arrays etc.) that people incorrectly consider the "normal" way to do things in C++.

If people stopped considering C++ as "C with additional stuff" and teaching it as such, maybe more people would see the language for what it is.

Reply Parent Score: 3

WereCatf Member since:

You have a problem with malloc? You probably believe such low level thing as bitwise AND (&) and OR (|) and bit shifts are bad? Let me guess, binary and hexidecimal are bad too? I think most C++ zealots are insecure about low-level computing concepts and want them to go away.

Please don't act like an idiot.. The parent never complained about malloc nor implied anywhere that doing bitwise operations is evil.. >_< He just probably meant that these a lot cleaner ways to handle strings than doing mallocs and managing the memory yourself. You do realize that it makes the code less readable and produces more code..?

PS. I happen to use C myself but that's just my taste. I still don't attack C++ users like you do.

Reply Parent Score: 3

sanctus Member since:

Of course it will catch as many error as possible, but when you compare python with C++ (or any compile vs runtime language), it's not accurate to say that all the errors you'll find will be somewhere undetected in a python program.

Just to bring one, there's many type in C++ that needed to be check where in python it doesn't matter at all. Like integer, in C++ the compiler need to check for int, long, unsigned, etc. In python, who cares? it's an integer. If you do some mixing in C++, the compiler will complain, but these errors are irrelevent in python. So as many errors in C++ are far less in python. (but I agree that some will not be check)

At the end it is a matter of design and the quality of code. Bad python code will end on error, bad c++ might throw a buffer overflow.

the first problem for portage that he said is :

Firstly, because Portage is a collection of procedural hacks thrown together over time with no underlying design.

I think this is the real issue. Not C++ or Python or whatever.

Reply Parent Score: 1