r/rust • u/slanterns • Oct 06 '23
Polonius update | Inside Rust Blog
https://blog.rust-lang.org/inside-rust/2023/10/06/polonius-update.html
279
Upvotes
r/rust • u/slanterns • Oct 06 '23
79
u/slanterns Oct 06 '23
> This post lays out a roadmap to try to get Polonius on stable by Rust 2024
32
u/bobozard Oct 06 '23
Is there any information on whether Polonius will help with self-referential structs?
9
u/Sharlinator Oct 06 '23
Could linkify "datalog" which I don't think is a familiar term to the vast majority of readers.
9
u/DanCardin Oct 07 '23
Both this and chalk seemed to have gone from "we can define these core rustc components as libraries which has nice downstream effects!" initially to "we learned from the library version but are deciding to do conceptually equivalent versions internally inside rustc"
I'm curious whether there is a long term plan re those nice downstream effects, if the efforts to do them as libraries are waning? (my impression being that things like rust-analyser and gcc-rs could have used these components as libraries to ensure maximal compatibility with rustc and reduce the scope of their concerns)
8
u/PolarBearITS Oct 06 '23
Maybe this question has been asked before, but will the rewrite of the borrow checker (or however you want to phrase incorporating Polonius into rustc) change how new Rust users learn about borrowing and lifetimes? Since Polonius introduces two new words regarding borrowing, namely origin and loan (the latter of which semantically means the same as "borrow", but has a subtly different definition), will these terms bleed into the "public api" so-to-speak of how new users will need to form their mental models of the borrow checker? Or, are these definitions only internal to the compiler and are basically an implementation detail?
3
u/klorophane Oct 06 '23
This is so exciting :D
1
u/Antique-Incident-758 Oct 08 '23
In step 5
Are we going to use a datalog engine here ?