std: deduplicate errno accesses

By marking `__errno_location` as `#[ffi_const]` and `std::sys::os::errno` as `#[inline]`, this PR allows merging multiple calls to `io::Error::last_os_error()` into one.
This commit is contained in:
joboet
2025-03-28 19:32:36 +01:00
parent 2a06022951
commit dd4f616423
2 changed files with 9 additions and 0 deletions

View File

@@ -297,6 +297,7 @@
#![feature(extended_varargs_abi_support)]
#![feature(f128)]
#![feature(f16)]
#![feature(ffi_const)]
#![feature(formatting_options)]
#![feature(if_let_guard)]
#![feature(intra_doc_pointers)]