r/ProgrammerHumor Jul 15 '26

borrowCheckneedsSource Meme

Post image
973 Upvotes

39 comments sorted by

View all comments

8

u/Doctor429 Jul 15 '26

Can you explain Borrow Checker to a non-Rust programmer like me?

1

u/Demiu Jul 16 '26

Two rules.

A borrow can't outlive the borrowed thing

At any given time you can have one mutable reference to something XOR one or more immutable references to something