Skip to content

Cleanup some Windows stuff, delete unused functions and kernel32 bindings#26030

Merged
squeek502 merged 2 commits intoziglang:masterfrom
squeek502:windows-cleanup
Nov 24, 2025
Merged

Cleanup some Windows stuff, delete unused functions and kernel32 bindings#26030
squeek502 merged 2 commits intoziglang:masterfrom
squeek502:windows-cleanup

Conversation

@squeek502
Copy link
Member

@squeek502 squeek502 commented Nov 24, 2025

Contributes towards #4426 (also relevant: #1840)

Deleted pub functions (all completely unused by Zig):

  • std.os.accessW
  • std.os.windows.CreateEventEx
  • std.os.windows.CreateEventExW
  • std.os.windows.FindClose
  • std.os.windows.MoveFileEx
  • std.os.windows.MoveFileExW
  • std.os.windows.GetFileAttributes
  • std.os.windows.GetFileAttributesW
  • std.os.windows.VirtualAlloc
  • std.os.windows.VirtualFree
  • std.os.windows.VirtualQuery

This also unifies the rename implementations, since previously `posix.renameW` used `MoveFileEx` while `posix.renameatW` used `NtOpenFile`/`NtSetInformationFile`. This, in turn, allows the `MoveFileEx` bindings to be deleted as `posix.renameW` was the only usage.
@squeek502 squeek502 enabled auto-merge November 24, 2025 08:05
@squeek502 squeek502 added the breaking Implementing this issue could cause existing code to no longer compile or have different behavior. label Nov 24, 2025
@squeek502 squeek502 merged commit ccc5e58 into ziglang:master Nov 24, 2025
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

breaking Implementing this issue could cause existing code to no longer compile or have different behavior.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant