5 ms·
I'm sorry, but I feel like all these "Just use Rust!" comments are written by idealistic college students. Yes, maybe Rust is better, and maybe if we could pus
by something123 11y ago
I'm sorry, but I feel like all these "Just use Rust!" comments are written by idealistic college students.
Yes, maybe Rust is better, and maybe if we could push a button and make everyone use it the world would be a better place.
But the reality is that there are very few code bases written in Rust and an uncountable amount written in C++ - there are decades of work behind C++ and decades of work will still be done in C++. I need to earn a living TODAY and work in the current reality, and I need tools to help me be more productive. I can't wait 5 years for some brand new language to take over.
- yokohummer7 11y agoI think you're misinterpreting what pcwalton said. Sure, seeing "use Rust" in every possible place is quite annoying, but what pcwalton described is why "compiles to C++" and "has 2 decades of libraries" don't work for new languages. He didn't say to use Rust, he was just pointing out that your two ideas aren't viable.
- kllrnohj 11y ago> But the reality is that there are very few code bases written in Rust and an uncountable amount written in C++ Most libraries use a C ABI due to it being stable, and Rust has fantastic FFI support for C (although tools to take in a .h and spit out the FFI in Rust are definitely needed). There's no performance cost to FFI in Rust, either, it's just a function call. As someone that spends a lot of time in an existing C++ codebase, FFI with zero overhead offers a very enticing migration path. But as you were asking about making a new language, I was just pointing out the language you were starting to design has already been built.
- kllrnohj 11y ago> But the reality is that there are very few code bases written in Rust and an uncountable amount written in C++ Most libraries use a C ABI due to it being stable, and Rust has fantastic FFI support for C (although tools to take in a .h and spit out the FFI in Rust are definitely needed). There's no performance cost to FFI in Rust, either, it's just a function call. As someone that spends a lot of time in an existing C++ codebase, FFI with zero overhead offers a very enticing migration path. But as you were asking about making a new language, I was just pointing out the language you were starting to design has already been built.