3 ms·
I wouldn't call smart pointers an "upgrade". If you are using smart pointers, you are not using the same language. There are many features of C++ that would ma
by GuB-42 6y ago
I wouldn't call smart pointers an "upgrade". If you are using smart pointers, you are not using the same language.
There are many features of C++ that would make a "better C", like namespaces and templates (which are better macros). But as good as they are in other contexts, smart-pointers are the last thing I want in C-like code.
Also, an advantage of C over C++ is that it doesn't have a runtime and it doesn't use name mangling. That makes linking much easier and particularly well suited to embedded applications.
- ModernMech 6y agoC has a tiny little runtime: https://en.m.wikipedia.org/wiki/Crt0 https://en.m.wikipedia.org/wiki/Crt0