3 ms·
I’m slightly unconvinced by the learning curve thing about rust. C++ has a high learning curve too but it is used very widely. I don’t really think rust has a h
by dan-robertson 8y ago
I’m slightly unconvinced by the learning curve thing about rust. C++ has a high learning curve too but it is used very widely. I don’t really think rust has a higher learning curve than C++. The main differences are the borrow checking (instead of having to learn and unreliable manually check memory usage everywhere), the type system having more ML-style polymorphism instead of crazy templates, and instead of inheritance with tables being implied by class, vtables are independent things (ie traits) and work largely like implementing multiple interfaces in c++ but without the inheritance and with implied instances from some rules.
The rest of the differences are just having different standard libraries/tool chains. I don’t think that, for a novice knowing neither, rust is somehow much harder than c++
- chipperyman573 8y agoC and C++ are also both taught in almost every university (at least in America but I assume in other places as well). You can't really say the same for rust.
- steveklabnik 8y agoThere have been university classes on Rust, but nowhere near C++ or Java, it’s true.
- dan-robertson 8y agoC is nearly 50 years old. C++ is 35 years old. Rust is 8 years old. Rust 1.0 is 4 years old. I think it is reasonable to guess that this is the reason rust is not taught so much at universities. Especially at universities which choose things based on what they think industry wants or what the professors know as this will lag behind actual trends in industry too. I think this argument only really applies to rust’s learning curve if one assumes that each year universities asses the programming language world for the best teaching languages and pick out those which can be used for the courses and are easiest to use. They obviously do not do this and you can tell because they picked c++ (which is actually at least three languages to learn with the preprocessor macros and the functional programming language that is hidden in the template system)
- mrath 8y agoI love Rust and all my personal side projects are in Rust nowadays. But rust is definitely not close to the learning curve of golang and Java. In comparison with C++ I am not too sure.