Re:The long goodbye to C
by shmerl on Friday November 10, 2017 @11:38AM
(#15671025)
I agree with the sentiment, but not with the idea that Go is a suitable general replacement for C. Rust on the other hand fits that role.
[ Parent
| on HN ]
And the issue is mostly the garbage collector, not any other language features or compiler optimization improvements. You just can't have GC in a systems language.
Mostly. Rust also tends to provide explicit control, which makes it more complicated, but aligns more with the approach of C to that.
As someone explained to me, it's the reason Rust doesn't have a nice initializer syntax like C++11 for example[1].
1. http://en.cppreference.com/w/cpp/language/list_initializatio...
I'm not sure I would call it a nice syntax. std::initializer_list was a questionable addition to C++ because its syntax clashes with other forms of initialization. It ends up creating special cases and complicating generic code. They fixed some of its problems in C++14, and we might see more improvements in C++20, but the entire idea of that syntax creating a special object feels like a mistake.