Skip to content

Commit 30a574a

Browse files
authored
Remove use of std in windows-strings macro (#3356)
1 parent d41381d commit 30a574a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

crates/libs/strings/src/literals.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ macro_rules! h {
4444
#[allow(clippy::declare_interior_mutable_const)]
4545
const RESULT: $crate::HSTRING = {
4646
if OUTPUT_LEN == 1 {
47-
unsafe { ::std::mem::transmute(::std::ptr::null::<u16>()) }
47+
unsafe { ::core::mem::transmute(::core::ptr::null::<u16>()) }
4848
} else {
4949
const OUTPUT: $crate::PCWSTR = $crate::w!($s);
5050
const HEADER: $crate::HSTRING_HEADER = $crate::HSTRING_HEADER {
@@ -56,7 +56,7 @@ macro_rules! h {
5656
};
5757
// SAFETY: an `HSTRING` is exactly equivalent to a pointer to an `HSTRING_HEADER`
5858
unsafe {
59-
::std::mem::transmute::<&$crate::HSTRING_HEADER, $crate::HSTRING>(&HEADER)
59+
::core::mem::transmute::<&$crate::HSTRING_HEADER, $crate::HSTRING>(&HEADER)
6060
}
6161
}
6262
};

0 commit comments

Comments
 (0)