Skip to content

Commit 7e7da49

Browse files
committed
Update a cranelift patch file for formatting changes.
PR #125443 will reformat all the use declarations in the repo. This would break a patch kept in `rustc_codegen_cranelift` that gets applied to `library/std/src/sys/pal/windows/rand.rs`. So this commit formats the use declarations in `library/std/src/sys/pal/windows/rand.rs` in advance of #125443 and updates the patch file accordingly. The motivation is that #125443 is a huge change and we want to get fiddly little changes like this out of the way so it can be nothing more than an `x fmt --all`.
1 parent b5b1356 commit 7e7da49

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

compiler/rustc_codegen_cranelift/patches/0029-stdlib-rawdylib-processprng.patch

+3-3
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ diff --git a/library/std/src/sys/pal/windows/c.rs b/library/std/src/sys/pal/wind
1212
index ad8e01bfa9b..9ca8e4c16ce 100644
1313
--- a/library/std/src/sys/pal/windows/c.rs
1414
+++ b/library/std/src/sys/pal/windows/c.rs
15-
@@ -323,7 +323,7 @@ pub unsafe fn NtWriteFile(
15+
@@ -312,7 +312,7 @@ pub unsafe fn NtWriteFile(
1616

1717
// Use raw-dylib to import ProcessPrng as we can't rely on there being an import library.
1818
cfg_if::cfg_if! {
@@ -26,8 +26,8 @@ index e427546222a..f2fe42a4d51 100644
2626
--- a/library/std/src/sys/pal/windows/rand.rs
2727
+++ b/library/std/src/sys/pal/windows/rand.rs
2828
@@ -2,7 +2,7 @@
29-
use core::mem;
30-
use core::ptr;
29+
30+
use crate::sys::c;
3131

3232
-#[cfg(not(target_vendor = "win7"))]
3333
+#[cfg(any())]

library/std/src/sys/pal/windows/rand.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1+
use core::{mem, ptr};
2+
13
use crate::sys::c;
2-
use core::mem;
3-
use core::ptr;
44

55
#[cfg(not(target_vendor = "win7"))]
66
#[inline]

0 commit comments

Comments
 (0)