Memory safety is good. If you can make it happen, by all means you should. If 
you can't, it is okay to have manual memory management. There is nothing wrong 
with it.

Some people tend to think that C/C++ bugs result from its manual memory 
management. That is not entirely accurate. The occurrence of bugs correlates 
with the number of things that the programmer has to handle. The more things 
the programmer has to manage, the more likely bugs will result. Bugs are 
essentially programmer's lapses.

When a language decides to add three new keywords, it does not result in three 
new additional cases. The true cost is the extra combination and permutation of 
the new features together with existing features. That is the true number of 
cases that the programmer has to deal with as the result of adding the three 
new keywords.

In the case of C++, since the language aims to be backward compatible and the 
committee has no restrain in adding features, what you get is a language with 
35 years worth of every imaginable features. Many end up using a subset of C++ 
for good reasons. In the case of Rust, can you imagine using the language if 
the compiler does not perform all those sophisticated analysis so that you can 
use the language correctly?

Anyhow, my point is that if Nim has to resort to manual memory management in 
order to keep the language simple, there is really nothing wrong with it. 

Reply via email to