silence cast_lossless clippy lint from triggering inside macros
This commit is contained in:
@@ -73,6 +73,7 @@ pub unsafe extern "C" fn strtoumax(
|
||||
}
|
||||
|
||||
/// See <https://pubs.opengroup.org/onlinepubs/9799919799/functions/wcstoimax.html>.
|
||||
#[expect(clippy::cast_lossless)] // not all users of `wcsto_impl!` are lossless
|
||||
#[unsafe(no_mangle)]
|
||||
pub unsafe extern "C" fn wcstoimax(
|
||||
mut ptr: *const wchar_t,
|
||||
|
||||
@@ -30,6 +30,7 @@ macro_rules! wc_as_char {
|
||||
};
|
||||
}
|
||||
|
||||
#[expect(clippy::cast_lossless)] // not all users of `parse_type!` are lossless
|
||||
pub unsafe fn inner_scanf<T: Kind>(
|
||||
mut r: Reader<T>,
|
||||
format: Reader<T>,
|
||||
|
||||
@@ -1473,6 +1473,7 @@ pub unsafe fn convert_integer(s: *const c_char, base: c_int) -> Option<(c_ulong,
|
||||
}
|
||||
|
||||
/// See <https://pubs.opengroup.org/onlinepubs/9799919799/functions/strtod.html>.
|
||||
#[expect(clippy::cast_lossless)] // not all users of `strto_float_impl!` are lossless
|
||||
#[unsafe(no_mangle)]
|
||||
pub unsafe extern "C" fn strtod(s: *const c_char, endptr: *mut *mut c_char) -> c_double {
|
||||
strto_float_impl!(c_double, s, endptr)
|
||||
|
||||
@@ -863,6 +863,7 @@ pub unsafe extern "C" fn wcstol(
|
||||
}
|
||||
|
||||
/// See <https://pubs.opengroup.org/onlinepubs/9799919799/functions/wcstoll.html>.
|
||||
#[expect(clippy::cast_lossless)] // not all users of `wcsto_impl!` are lossless
|
||||
#[unsafe(no_mangle)]
|
||||
pub unsafe extern "C" fn wcstoll(
|
||||
mut ptr: *const wchar_t,
|
||||
|
||||
Reference in New Issue
Block a user