Rollup merge of #138040 - thaliaarchi:use-prelude-size-of.compiler, r=compiler-errors
compiler: Use `size_of` from the prelude instead of imported Use `std::mem::{size_of, size_of_val, align_of, align_of_val}` from the prelude instead of importing or qualifying them. Apply this change across the compiler. These functions were added to all preludes in Rust 1.80. r? ``@compiler-errors``
This commit is contained in:
commit
c6662879b2
30 changed files with 64 additions and 74 deletions
|
@ -92,7 +92,7 @@ fn current_dll_path() -> Result<PathBuf, String> {
|
|||
if libc::loadquery(
|
||||
libc::L_GETINFO,
|
||||
buffer.as_mut_ptr() as *mut u8,
|
||||
(std::mem::size_of::<libc::ld_info>() * buffer.len()) as u32,
|
||||
(size_of::<libc::ld_info>() * buffer.len()) as u32,
|
||||
) >= 0
|
||||
{
|
||||
break;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue