3 ms·
> The basic problem with C++ is that it has heavy encapsulation without memory safety. No other language has that. I think in general these things are unrelate
by yoklov 9y ago
> The basic problem with C++ is that it has heavy encapsulation without memory safety. No other language has that.
I think in general these things are unrelated, unless you stretch the definition of memory safety rather far.
Also, you can hide things in C, just it's not always zero cost. Put private fields in a forward declared struct that's not implemented in any headers, use static for private functions (also outside of headers).