We're sorry but this page doesn't work properly without JavaScript enabled. Please enable it to continue.
Feedback

Polonius: Either Borrower or Lender Be, but Responsibly

Formal Metadata

Title
Polonius: Either Borrower or Lender Be, but Responsibly
Title of Series
Number of Parts
15
Author
License
CC Attribution 3.0 Unported:
You are free to use, adapt and copy, distribute and transmit the work or content in adapted or unchanged form for any legal purpose as long as the work is attributed to the author in the manner specified by the author or licensor.
Identifiers
Publisher
Release Date
Language

Content Metadata

Subject Area
Genre
Abstract
Rust 2018 brought with it “non-lexical lifetimes” (NLL), a big overhaul of how the borrow checker worked that allowed it to accept a lot more programs. And yet, we’re still not accepting the full range of programs that was envisioned by the original NLL RFC – this is both for performance reasons and because the formulation didn’t turn out to be as flexible as originally thought. Polonius is a “reframing” of Rust’s borrow checker. It works quite differently than the original system. Rather than tracking how long each reference is used (its “lifetime”), it tracks where each reference may have come from (its “origin”) – and it does so in a very fine-grained way. As a result, Polonius is able to accept all the programs that the NLL RFC envisioned, and a few more! We also believe it can be made more performant (though that has yet to be fully proven out). This talk will explain how Polonius works in a simple and example-driven style. It will help you to gain a deeper understanding of how Rust’s borrow checker works internally. --- Note from the conference: The slides for this talk were not captured and we've re-recorded them after the fact. Some of the visuals did not work perfectly, and for that we apologize.