3 ms·
Well you learn to appreciate the value of RAII and exception working on high-availability software. It's almost impossible to have correct error paths and deini
by p0nce 8y ago
Well you learn to appreciate the value of RAII and exception working on high-availability software. It's almost impossible to have correct error paths and deinitialization without. I'm very doubtful the new crop of languages without exceptions and RAII actually care about correctness in the wild.
Better than template without uniform representation? template is just copy-paste you don't _have_ to use it. Same remark for STL. You want a hashmap of arrays of string, you can have it in C++ in one line. In C you would end up with a linked list instead of picking the right data structure.
Objects and inheritance are not a hype. See this page, which uses CSS, which implements inheritance. Having subtyping is a basic premise of being a useful language (or, a GUI language).
- tomp 8y ago> Well you learn to appreciate the value of RAII and exception working on high-availability software. Alternatively, you'll learn to not appreciate the value of exceptions working on high-availability software. Not personal experience, but AFAIK Google (definitely lots of highly-available software) disallows using exceptions in C++.
- erik_seaberg 8y agoThey have a critical mass of bad legacy code. > Because most existing C++ code at Google is not prepared to deal with exceptions, it is comparatively difficult to adopt new code that generates exceptions[....] Things would probably be different if we had to do it all over again from scratch. - https://google.github.io/styleguide/cppguide.html#Exceptions https://google.github.io/styleguide/cppguide.html#Exceptions
- flohofwoe 8y agoI've been writing C++ code since around '98, and have only recently moved back to mostly C. To be honest, features in C++ that I thought are a "must have" are actually a variant of Stockholm Syndrome, after a little while (a few weeks to months) one realizes that the world would keep turning without C++ ;)
- p0nce 8y agoNone of my competitors use a language from the 70's.