Closed
Description
Currently, the RefCell borrow guards have a function called map
which allows you to transform a borrow of a whole struct to a borrow of one of its fields (or of some related reference with the same lifetime). Would it be possible to add these methods to Mutex and RwLock?