Skip to content
Free public beta until December 4, 2026: every course is open, no card needed. After that, the first chapter of each course stays free and full access is a one-time $39 ($19 for up to 100 founding members chosen for helpful feedback). Your progress is kept. How the beta works

receiver

The self parameter: how a method gets the value it is called on.

A method's receiver self/&self/&mut self decides whether it takes ownership, borrows, or borrows mutably.

Examples

  • fn into_title(self) takes the whole value, so after book.into_title() using book.title fails with E0382; &self would only borrow it.

Read the full section →