Rollup merge of #118147 - Nilstrieb:no-redundant-casts, r=WaffleLapkin
Fix some unnecessary casts `x clippy compiler -Aclippy::all -Wclippy::unnecessary_cast --fix` with some manual review to ensure every fix is correct.
This commit is contained in:
commit
040151a4be
10 changed files with 18 additions and 30 deletions
|
@ -2268,11 +2268,7 @@ fn encode_metadata_impl(tcx: TyCtxt<'_>, path: &Path) {
|
|||
file.seek(std::io::SeekFrom::Start(pos_before_seek)).unwrap();
|
||||
|
||||
// Record metadata size for self-profiling
|
||||
tcx.prof.artifact_size(
|
||||
"crate_metadata",
|
||||
"crate_metadata",
|
||||
file.metadata().unwrap().len() as u64,
|
||||
);
|
||||
tcx.prof.artifact_size("crate_metadata", "crate_metadata", file.metadata().unwrap().len());
|
||||
}
|
||||
|
||||
pub fn provide(providers: &mut Providers) {
|
||||
|
|
|
@ -497,7 +497,7 @@ impl<I: Idx, const N: usize, T: FixedSizeEncoding<ByteArray = [u8; N]>> TableBui
|
|||
}
|
||||
|
||||
LazyTable::from_position_and_encoded_size(
|
||||
NonZeroUsize::new(pos as usize).unwrap(),
|
||||
NonZeroUsize::new(pos).unwrap(),
|
||||
width,
|
||||
self.blocks.len(),
|
||||
)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue