News for hackers. Stuff that matters.
Re:Why not C++? by pmarreck on Saturday March 05, 2016 @02:43PM (#11230713)
C++ is still plenty viable, but if you like avoiding bugs, John Carmack seems to have come to the conclusion that using a functional style (which is not exactly encouraged by C++) is advantageous: http://gamasutra.com/view/news/169296/Indepth_Functional_pro...

"My pragmatic summary: A large fraction of the flaws in software development are due to programmers not fully understanding all the possible states their code may execute in. In a multithreaded environment, the lack of understanding and the resulting problems are greatly amplified, almost to the point of panic if you are paying attention. Programming in a functional style makes the state presented to your code explicit, which makes it much easier to reason about, and, in a completely pure system, makes thread race conditions impossible.

"No matter what language you work in, programming in a functional style provides benefits. You should do it whenever it is convenient, and you should think hard about the decision when it isn't convenient."

There are no comments on this comment yet.