silence some unused-fn warnings in miri std builds

This commit is contained in:
Ralf Jung 2022-08-06 14:46:30 -04:00
parent 8c8dc125b1
commit 438e49c1cb

View File

@ -829,6 +829,7 @@ impl DirEntry {
target_os = "fuchsia",
target_os = "redox"
)))]
#[cfg_attr(miri, allow(unused))]
fn name_cstr(&self) -> &CStr {
unsafe { CStr::from_ptr(self.entry.d_name.as_ptr()) }
}
@ -840,6 +841,7 @@ impl DirEntry {
target_os = "fuchsia",
target_os = "redox"
))]
#[cfg_attr(miri, allow(unused))]
fn name_cstr(&self) -> &CStr {
&self.name
}