Hacker News new | ask | show | jobs
by fithisux 25 days ago
You can write C style C++ and enjoy the same benefits.

In Twitter a user explained me that it is common in embedded space.

You do not need the OOP, RTTI, exceptions.

Like C with most use cases of preprocessor replaced by generic programming.

1 comments

So? How is that an argument that C++ is more performant than C? It's only an argument that it's not less performant.
Because you can write C like code, while taking advantage of templates, compile time code execution, and eventually static reflection, that prepare work ahead of time, while at the same time giving more information to optimiser passes.
It is an argument that you can make a faster C-like if you like out of C++