Skip to content

Closures practice problems in Rust

Difficulty:
Category:
Tag:

Showing 15 of 15

Status Title Difficulty
Box<dyn Trait>: trait objects, DSTs and dynamic dispatch Medium
Closures 101: build a pipeline of boxed closures Easy
Closures hold their borrows Medium
Fn, FnMut, FnOnce: the closure hierarchy Medium
Folding an AST: separating traversal from action Hard
from_fn and successors: iterators without writing a struct Easy
Laziness: prove the pipeline interleaves Easy
move closures: why the compiler forces your hand Easy
move: when the closure must own its captures Medium
`poll_fn`: a future from a closure Easy
Returning impl Trait, and what edition 2024 changed Hard
The FnMut borrow gauntlet: a log you can read afterwards Medium
Trait objects and lifetimes: Box<dyn Trait + 'a> Hard
`T: 'static` in practice — a type-erased handler registry Hard
unsafe impl Send, and the disjoint-capture trap Hard