4 ms·
> It’s a big deal. Only time will tell, right now don’t see any real benefits. I do agree though rust is a good attempt to try. Right now majority of the rust
by dragonsh 7y ago
> It’s a big deal.
Only time will tell, right now don’t see any real benefits. I do agree though rust is a good attempt to try. Right now majority of the rust libraries depend on underlying C/C++ with unsafe code. Will watch how it will slowly replace Firefox use of C++.
Will wait and watch when rust will replace LLVM written in C++ with something completely written in rust. Although they replaced OCaml part with rust already so need to see when they can replace C++ dependency which is LLVM.
(My opinion might be biased as rust code reminds me of 1990’s and doesn’t look any different than C++, I like Swift syntax more)
- qchris 7y agoI'm sorry (genuinely, especially in light of your self-aware end comment), but I don't believe that this is a well-informed comment. Yes, there are Rust crates that are written as bindings to C++ libraries, where there isn't drop-in available Rust code available to use, or either a de-facto standard API and well-tested C++ codebase allow for this. Examples of this can be found in relatively niche, code-heavy areas like machine learning, with OpenCV and Tensorflow libraries available in Rust just calling to existing system installation. However, I think it's disingenuous to claim that either "a majority of the rust libraries" use bindings like that, or to suggest that Firefox is the primary project worth watching that uses Rust. As mentioned elsewhere in this thread, Rust articles and code examples fairly routinely show up here on HN. It's surely not complete, and any programming language or framework is an exercise in trade-offs, but from hacking on bare-metal or microcontrollers[1] to web GUIs with interactive physical simulations[2], Rust-only or Rust component code is showing up in a number of domains and production environments[3]. A lot of this is really seems to stem from a safety-by-overall-design rather than safety-by-specific-implementation approach, which seems to resonate well with both experienced developers and newcomers alike. [1] https://rust-embedded.github.io/book/ https://rust-embedded.github.io/book/ [2] https://nphysics.org/demo_all_examples3/ https://nphysics.org/demo_all_examples3/ [3] https://news.ycombinator.com/item?id=22238335 https://news.ycombinator.com/item?id=22238335 Edited for spelling/grammar
- dragonsh 7y agoI really like the development happening in rust to write some core libraries, but given most hardware still use C for development, I doubt rust will be able to escape the fact that it will have to be a wrapper around C with rust api layer on top of it. Firefox which is the reason for origin of rust, cannot yet be completely written in rust and will continue to be dependent on C++ for sometime. I feel like Python, Rust might become more popular once enough hardware and core libraries move away from C/C++ to Rust. It is still a decade or two away.
- steveklabnik 7y agoFirefox isn’t dependent on C++ because Rust is insufficient, it’s because porting (IIRC) fifteen MILLION lines of code just doesn’t happen overnight, and isn’t a direct focus.
- dragonsh 7y agoThat’s precisely the issue, until and unless enough libraries are created in Rust with little to no dependency on C/C++, it won’t be a significant language but will just be something similar to Haskell may be bit larger. So I still feel Rust needs another decade or two to be able to claim as C/C++ replacement, not at present. This is exactly the problem Swift faced to replace Objective-c, in Apple eco-system where everything controlled by Apple. Rust has much bigger hill to climb to be really useful systems programming language.