Skip to content

HardScenarioOwnership, borrowing and lifetimes

A struct needs to hold a reference to data owned by a sibling field and the borrow checker refuses. What do you do?

This answer is part of Pro

10 of 81 Rust Developer answers are free. A Pro pass opens the rest, including hands-on task steps.

More on Ownership, borrowing and lifetimes

Flashcards for this topic