-
No, you don't. Existential proof: mrustc ignores lifetimes. Just flat out simply ignores. It changes some corner-cases related to HRBT, yet rustc compiled by mrustc works (that's BTW mrustc exist: to bootsrap the rustc compiler).
-
SaaSHub
SaaSHub - Software Alternatives and Reviews. SaaSHub helps you find the best software and product alternatives
-
A model without lifetimes is also being explored in other languages, e.g. in Hylo. It sacrifices expressiveness, but on the other hand you don't have to deal with explicit lifetimes!
-
For now the closest thing to inferred lifetimes are closures, which are effectively functions where the signature is fully inferred, and they already give headaches around lifetime inference (see for example https://github.com/rust-lang/rust/issues/70263). If you never encountered this issue, it's because you always passed closures to functions which take a generic type F: Fn(...), and the compiler could use that Fn(...) as the signature of your closure, hence avoiding inferring it. But if that Fn(...) is not present (even just using another trait that has a Fn(...) supertrait) then everything breaks!
-
Correctness prover which uses lifetimes (Polonius).
-
That's why gccrs doesn't even consider lifetime checking a part of the language (they plan to use Polonius, too).
-
llvm-project
The LLVM Project is a collection of modular and reusable compiler and toolchain technologies.
C++ compiler which compiles the Rust as if it were C++ (LLVM).
Related posts
-
GCC Rust Approved by GCC Steering Committee
-
Adding a Rust compiler front end to GCC
-
Take your first steps with Rust
-
Why am I writing a Rust compiler in C?
-
How hard would it be to port the Rust toolchain to a new non-POSIX OS written in Rust and get it to host its own development? What would that process entail?