3 ms·
I read more than once that rust has no runtime. Could you please clarify whether it has a runime, and if it does, what it consists of?
by madez 12y ago
I read more than once that rust has no runtime. Could you please clarify whether it has a runime, and if it does, what it consists of?
- steveklabnik 12y agoSo, basically _every_ non-assembly programming language has a runtime. Even C and C++. But not all runtimes are created equal. Languages like C, C++, and Rust have a very minimal, no setup required runtime. Other, higher level languages often have something significantly more heavy. People will sometimes say "no runtime" to mean the class of languages which have very small runtimes. Rust's runtime is here: https://github.com/rust-lang/rust/tree/master/src/rt https://github.com/rust-lang/rust/tree/master/src/rt and https://github.com/rust-lang/rust/tree/master/src/libstd/rt https://github.com/rust-lang/rust/tree/master/src/libstd/rt As you can see, it's very, very small. It mostly handles things like unwinding, at_exit handlers, and the like.