rustc_metadata: replace ? in expression with map

This commit is contained in:
Tamir Duberstein 2024-10-15 11:14:34 -04:00
parent 93cee99368
commit f395551352
No known key found for this signature in database

View File

@ -755,7 +755,7 @@ fn find_commandline_library(&mut self) -> Result<Option<Library>, CrateError> {
}
// Extract the dylib/rlib/rmeta triple.
Ok(self.extract_lib(rlibs, rmetas, dylibs)?.map(|(_, lib)| lib))
self.extract_lib(rlibs, rmetas, dylibs).map(|opt| opt.map(|(_, lib)| lib))
}
pub(crate) fn into_error(self, root: Option<CratePaths>) -> CrateError {