Skip to content

Commit d9c85da

Browse files
committed
Update windows ffi bindings
1 parent 9f48a85 commit d9c85da

File tree

7 files changed

+104
-127
lines changed

7 files changed

+104
-127
lines changed

Cargo.lock

+7-11
Original file line numberDiff line numberDiff line change
@@ -5851,19 +5851,21 @@ dependencies = [
58515851

58525852
[[package]]
58535853
name = "windows-bindgen"
5854-
version = "0.49.0"
5854+
version = "0.51.1"
58555855
source = "registry+https://github.com/rust-lang/crates.io-index"
5856-
checksum = "b6935fb09b84ee57929ae92518b475f5dfdfbeb87c5334756acc28ee8e202b60"
5856+
checksum = "bc1f16b778125675feee0d15d6dd9f6af0e3ac52b3233d63a10aa39230c1cd75"
58575857
dependencies = [
5858+
"proc-macro2",
5859+
"rayon",
5860+
"syn 2.0.27",
58585861
"windows-metadata",
5859-
"windows-tokens",
58605862
]
58615863

58625864
[[package]]
58635865
name = "windows-metadata"
5864-
version = "0.49.0"
5866+
version = "0.51.1"
58655867
source = "registry+https://github.com/rust-lang/crates.io-index"
5866-
checksum = "2f5bca94a32bf1e6a376522b6601275a3b611ee885ec0f1b6a05f17e8cfd3385"
5868+
checksum = "753135d996f9da437c0b31dbde3032489a61708361929bcc07d4fba0b161000e"
58675869

58685870
[[package]]
58695871
name = "windows-sys"
@@ -5889,12 +5891,6 @@ dependencies = [
58895891
"windows_x86_64_msvc",
58905892
]
58915893

5892-
[[package]]
5893-
name = "windows-tokens"
5894-
version = "0.48.0"
5895-
source = "registry+https://github.com/rust-lang/crates.io-index"
5896-
checksum = "b34c9a3b28cb41db7385546f7f9a8179348dffc89923dde66857b1ba5312f6b4"
5897-
58985894
[[package]]
58995895
name = "windows_aarch64_gnullvm"
59005896
version = "0.48.0"

library/std/src/sys/windows/c.rs

+1-5
Original file line numberDiff line numberDiff line change
@@ -46,10 +46,6 @@ pub use FD_SET as fd_set;
4646
pub use LINGER as linger;
4747
pub use TIMEVAL as timeval;
4848

49-
pub type CONDITION_VARIABLE = RTL_CONDITION_VARIABLE;
50-
pub type SRWLOCK = RTL_SRWLOCK;
51-
pub type INIT_ONCE = RTL_RUN_ONCE;
52-
5349
pub const CONDITION_VARIABLE_INIT: CONDITION_VARIABLE = CONDITION_VARIABLE { Ptr: ptr::null_mut() };
5450
pub const SRWLOCK_INIT: SRWLOCK = SRWLOCK { Ptr: ptr::null_mut() };
5551
pub const INIT_ONCE_STATIC_INIT: INIT_ONCE = INIT_ONCE { Ptr: ptr::null_mut() };
@@ -224,7 +220,7 @@ pub unsafe extern "system" fn ReadFileEx(
224220
) -> BOOL {
225221
windows_sys::ReadFileEx(
226222
hFile.as_raw_handle(),
227-
lpBuffer,
223+
lpBuffer.cast::<u8>(),
228224
nNumberOfBytesToRead,
229225
lpOverlapped,
230226
lpCompletionRoutine,

library/std/src/sys/windows/c/windows_sys.lst

+3-5
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
--out windows_sys.rs
2+
--config flatten std
3+
--filter
14
// tidy-alphabetical-start
25
Windows.Wdk.Storage.FileSystem.FILE_COMPLETE_IF_OPLOCKED
36
Windows.Wdk.Storage.FileSystem.FILE_CONTAINS_EXTENDED_CREATE_INFORMATION
@@ -2108,7 +2111,6 @@ Windows.Win32.Networking.WinSock.WSABASEERR
21082111
Windows.Win32.Networking.WinSock.WSABUF
21092112
Windows.Win32.Networking.WinSock.WSACleanup
21102113
Windows.Win32.Networking.WinSock.WSADATA
2111-
Windows.Win32.Networking.WinSock.WSADATA
21122114
Windows.Win32.Networking.WinSock.WSADuplicateSocketW
21132115
Windows.Win32.Networking.WinSock.WSAEACCES
21142116
Windows.Win32.Networking.WinSock.WSAEADDRINUSE
@@ -2420,8 +2422,6 @@ Windows.Win32.System.Console.STD_OUTPUT_HANDLE
24202422
Windows.Win32.System.Console.WriteConsoleW
24212423
Windows.Win32.System.Diagnostics.Debug.ARM64_NT_NEON128
24222424
Windows.Win32.System.Diagnostics.Debug.CONTEXT
2423-
Windows.Win32.System.Diagnostics.Debug.CONTEXT
2424-
Windows.Win32.System.Diagnostics.Debug.CONTEXT
24252425
Windows.Win32.System.Diagnostics.Debug.EXCEPTION_RECORD
24262426
Windows.Win32.System.Diagnostics.Debug.FACILITY_CODE
24272427
Windows.Win32.System.Diagnostics.Debug.FACILITY_NT_BIT
@@ -2435,7 +2435,6 @@ Windows.Win32.System.Diagnostics.Debug.FORMAT_MESSAGE_OPTIONS
24352435
Windows.Win32.System.Diagnostics.Debug.FormatMessageW
24362436
Windows.Win32.System.Diagnostics.Debug.M128A
24372437
Windows.Win32.System.Diagnostics.Debug.XSAVE_FORMAT
2438-
Windows.Win32.System.Diagnostics.Debug.XSAVE_FORMAT
24392438
Windows.Win32.System.Environment.FreeEnvironmentStringsW
24402439
Windows.Win32.System.Environment.GetCommandLineW
24412440
Windows.Win32.System.Environment.GetCurrentDirectoryW
@@ -2456,7 +2455,6 @@ Windows.Win32.System.Kernel.ExceptionContinueExecution
24562455
Windows.Win32.System.Kernel.ExceptionContinueSearch
24572456
Windows.Win32.System.Kernel.ExceptionNestedException
24582457
Windows.Win32.System.Kernel.FLOATING_SAVE_AREA
2459-
Windows.Win32.System.Kernel.FLOATING_SAVE_AREA
24602458
Windows.Win32.System.Kernel.OBJ_DONT_REPARSE
24612459
Windows.Win32.System.LibraryLoader.GetModuleFileNameW
24622460
Windows.Win32.System.LibraryLoader.GetModuleHandleA

0 commit comments

Comments
 (0)