3 ms·
C++ has gotten a lot better with C++11/14/17. It's almost like a new language now. I agree the syntax is not the nicest. But not having a GC is not really that
by winter_blue 10y ago
C++ has gotten a lot better with C++11/14/17. It's almost like a new language now. I agree the syntax is not the nicest. But not having a GC is not really that big of a problem. I honestly (literally) never have memory-related problems while writing C++ because I either use smart pointers, or always allocate/free objects in the constructor & destructor. I rarely even find myself calling 'new' because everything gets allocated by the STL containers. There certainly is more effort involved in this, vs. using a language with GC, but that's the (small) price in effort you pay for far more efficient memory usage and no arbitrary GC freezes.