Live data from Hacker News

C++ is not a superset of C

mcla.ug

111–114 of 114 posts

Re: C++ is not a superset of C

#111
post #99
post #81

Earlier quoted context omitted.

You're high. In industry C and C++ are very widespread. Go and Rust are ... not. You'll have an easier time finding a job that requires FORTRAN than one requiring Rust, and Go is only a bit more popular.

Lets touch base again in five years and see how C++ is doing.

You seem to underestimate the vast amounts of existing C++ and C code. That code is not going anywhere, especially in only 5 years. Companies are not going to rewrite stuff in Rust just because of memory and type safety.

Touch base in 5 years... Rust will still be a niche language due to its complexity. (IMO, Go has a better chance of at least picking up a few percentage points.)

Re: C++ is not a superset of C

#112
post #99

Earlier quoted context omitted.

Lets touch base again in five years and see how C++ is doing.

You seem to underestimate the vast amounts of existing C++ and C code. That code is not going anywhere, especially in only 5 years. Companies are not going to rewrite stuff in Rust just because of memory and type safety. Touch base in 5 years... Rust will still be a niche language due to its complexity. (IMO, Go has a better chance of at least picking up a few percentage points.)

C++ is noticeably safer than C but C is still more widespread. Safety doesn't really sell.

Re: C++ is not a superset of C

#113
post #74
post #57

Earlier quoted context omitted.

I am hoping this isn’t an implication that C is legacy and C++ is the modern and the future. :-)

C is a niche language and C++ is about to hit the wall as companies abandon it for languages like Go and Rust.

I write C every day in embedded RISC-V. I think Rust looks neat, and would find it cool to use. But I just convinced the team to move off of gnu90, and a huge amount of my work is in assembly.

Rust offers the idea of safety and security, but at the same time hedges itself with unsafe - fine, sure. However, my work would be nearly 100% in unsafe. So it results in an unpredictable, complex, unsafe language - a non starter.

Re: C++ is not a superset of C

#114
post #64

Earlier quoted context omitted.

> [Classes, templates, and exceptions are] not the "problems" with C++, they're what make C++ great. We're going to have to agree to disagree on that one. > It's like C is slowly realizing C++ features are actually useful, but doing so as slowly as molasses, while still trying to pretend like this isn't the case... I think it makes sense to adopt C++ features that do some combination of (1) providing a useful feature…

C with templates (not classes), STL algorithms/ranges and small things like nullptr, auto, lambdas, stronger basic types, etc is actually a powerful configuration.

Everyone who likes C++ will tell you which parts they like and how powerful they are :-).
Post reply on HN