3 ms·
I might argue that those who thought the problems with mutable-by-default multithreading could be solved with proper programmer discipline also didn't understan
by kps 4y ago
I might argue that those who thought the problems with mutable-by-default multithreading could be solved with proper programmer discipline also didn't understand it.
- gonzo 4y agoI think this was the joke..
- Someone 4y agoBut it can be solved trivially with proper discipline. ‘Mutable by default’ implies there’s a way to make things immutable, and proper discipline can make everything immutable. The problem is that no human can maintain proper discipline at all times, and it takes only one slip to create a bug. And yes, programmers doing that would soon realize that ‘immutable by default’ leads to a better UX of a programming language. It’s way easier to be alerted by a warning ‘mutable’ keyword than by a missing ‘immutable’ one) That’s why we should have linters that flag all missing ‘immutable’ annotations or incorrect usage of ‘mutable’ ones. Rust even adds something like that to the language.