2 ms·
Any time 'it matters'. There's lots of stuff that we build, and we say things like, "Language X is slow, but it doesn't matter." "Language Y uses a lot of memo
by steveklabnik 12y ago
Any time 'it matters'.
There's lots of stuff that we build, and we say things like, "Language X is slow, but it doesn't matter." "Language Y uses a lot of memory, but it doesn't matter." This is very, very often true. But every once in a while, it really matters.
That's when you want something like Rust. When the details are important. When you need full control, but you'd like a compiler to help catch your mistakes. When a garbage collector has too much overhead. When you need to write something inside of Language X or Y, instead of a C extension, you can use Rust.
Basically, anywhere you'd use C or C++, Rust is a great fit. Elsewhere? Maybe, maybe not. Depends.
- robertfw 12y ago> When you need to write something inside of Language X or Y, instead of a C extension, you can use Rust. Are there any examples/discussion/information for interacting with rust from python, like you would a C extension?
- steveklabnik 12y agoI devoted a whole chapter of the book to Ruby/Python/node embedding: http://doc.rust-lang.org/book/rust-inside-other-languages.html http://doc.rust-lang.org/book/rust-inside-other-languages.ht... A Ruby gem in Rust was one of our earliest production uses.
- barosl 12y agoThere's a wonderful presentation on this topic: https://www.youtube.com/watch?v=3CwJ0MH-4MA https://www.youtube.com/watch?v=3CwJ0MH-4MA