C vs. C++

cs.ucr.edu/~neamtiu/pubs/icse11bhattacharya.pdf

Why do you still use C?

Attached: serveimage.png (488x441, 41K)

less clusterfuckd than C++. i tend to use both though, just for different use cases

I prefer ANSI C over C++ for embedded devices. It's rare in most cases that I need any of the fanciful features C++ adds

java

This. No reason to dick around with C++ for embedded devices that accept no remote user input.

Because Pajeets hate it )as evidenced by the article you posted) so by working on projects that use C instead of other languages, I reduce the chance I will work with one.

yes, exactly. Even in some networking applications simple buffers with bounds checking is enough. Rarely though is this even needed. Most things I make are simple loops our counters for things like flow regulators, etc. This is not tricky code.

Faster compile times, faster and more compact executables, easier to code in and most of all it isn't and never will be C++, not ever.

No oop so it's not easier to code in

>Why do you still use C?
Because the existing code base is in C, and I work mostly in kernel space.

I absolutely prefer C++ over C though, don't get me wrong.

Consider converting the code to C++. It's usually pretty easy to do.

Make it compile able with c++ compiler I mean.

Attached: 1512822825519.jpg (442x500, 8K)

We have to deal with VxWorks, Linux, Solaris and Windows and maintain compatibility between those, so I doubt that it would be feasible.

>We have to deal with VxWorks, Linux, Solaris and Windows and maintain compatibility between those, so I doubt that it would be feasible.

Big & Little endian? yowza. What sort of work is this, gov't contractor or something?

>What sort of work is this, gov't contractor or something?
We do that too, although technically that's the daughter company since technically only US companies can be contracted for the US army. But primarily we do anything from rugged environment to supercomputers and clusters.

makes sense. I had to maintain some insanely outdated dependencies working for contractors in afghanistan. they had some ubiquiti tower network that plugged back into old Sun, VAX, and IBM 3270 systems.

Same with a civic infrastructure job I had, I don't even want to think about how old and outdated the shit running the country is.

C is simpler and less confusing. It also doesn't tempt you to use costly abstractions. There are still reasons to use C++.

anime website

The horrors I could tell you about, user... I've actually encountered K&R C in our code base, as in
foo(a, b) /* foo is assumed int here */
int a;
char* b;
{
/* ... */
}

That's how old some of this stuff is.

fun fact, my coworker is an old caltech dude like 30 years my senior. He showed me usenet posts of him troubleshooting udp sockets in C and Richie himself replying lol

That's pretty cool.

We do kernel stuff in C by convention and Cpp is used for everything else. I strongly prefer working with a Cpp code base as it is a lot easier to work with.