Add doc for deconstruct_option_or_result

This commit is contained in:
Lzu Tao 2024-07-11 05:10:20 +00:00
parent 872d7b82e1
commit a776e5f922
1 changed files with 3 additions and 0 deletions

View File

@ -521,6 +521,9 @@ impl<'a, 'tcx> FnCtxt<'a, 'tcx> {
false
}
/// If `ty` is `Option<T>`, returns `T, T, None`.
/// If `ty` is `Result<T, E>`, returns `T, T, Some(E, E)`.
/// Otherwise, returns `None`.
fn deconstruct_option_or_result(
&self,
found_ty: Ty<'tcx>,