Allow access to the underlying `Results` from a `ResultsCursor`

This commit is contained in:
Dylan MacKenzie 2020-08-27 23:03:21 -07:00
parent a88dc37c54
commit 9e45e90596
1 changed files with 6 additions and 1 deletions

View File

@ -68,7 +68,12 @@ where
self.body
}
/// Returns the `Analysis` used to generate the underlying results.
/// Returns the underlying `Results`.
pub fn results(&self) -> &Results<'tcx, A> {
&self.results.borrow()
}
/// Returns the `Analysis` used to generate the underlying `Results`.
pub fn analysis(&self) -> &A {
&self.results.borrow().analysis
}