Bug 10469 – WinAPI declarations in std.process should be moved to core.sys.windows.windows

Status
RESOLVED
Resolution
FIXED
Severity
normal
Priority
P2
Component
phobos
Product
D
Version
D2
Platform
All
OS
All
Creation time
2013-06-24T15:25:00Z
Last change time
2013-06-24T23:40:06Z
Keywords
pull
Assigned to
andrej.mitrovich
Creator
andrej.mitrovich

Comments

Comment #0 by andrej.mitrovich — 2013-06-24T15:25:08Z
These Windows API declarations should be moved out of std.process and into core.sys.windows.windows: ----- version (Windows) { extern(Windows) BOOL GetHandleInformation(HANDLE hObject, LPDWORD lpdwFlags); extern(Windows) BOOL SetHandleInformation(HANDLE hObject, DWORD dwMask, DWORD dwFlags); extern(Windows) BOOL TerminateProcess(HANDLE hProcess, UINT uExitCode); extern(Windows) LPWSTR* CommandLineToArgvW(LPCWSTR lpCmdLine, int* pNumArgs); enum { HANDLE_FLAG_INHERIT = 0x1, HANDLE_FLAG_PROTECT_FROM_CLOSE = 0x2, } enum CREATE_UNICODE_ENVIRONMENT = 0x400; } ----- The reason why is because code which uses both the WindowsAPI[1] project and std.process together can fail to build due to conflicts. It's mostly the enum definitions that are the problem, but we should move the function declarations to core.sys.windows.windows as well. [1] : http://www.dsource.org/projects/bindings/wiki/WindowsApi
Comment #1 by andrej.mitrovich — 2013-06-24T15:38:06Z
Comment #2 by github-bugzilla — 2013-06-24T17:59:53Z
Commits pushed to master at https://github.com/D-Programming-Language/druntime https://github.com/D-Programming-Language/druntime/commit/e12b000d05e6fa6d4bd08c611504ca4bf912f510 Fixes Issue 10469 - Move WinAPI prototypes and enums need by std.process into core.sys.windows.windows. https://github.com/D-Programming-Language/druntime/commit/3e51a556de7e943ddd026f8beb35ffccfc9cf408 Merge pull request #533 from AndrejMitrovic/Fix10469 Issue 10469 - Move WinAPI prototypes and enums need by std.process to core.sys.windows.windows
Comment #3 by github-bugzilla — 2013-06-24T22:56:59Z
Commits pushed to master at https://github.com/D-Programming-Language/phobos https://github.com/D-Programming-Language/phobos/commit/f7b36b9124b8e0769d2a8a318745d5e9c4d61fda Fixes Issue 10469 - Remove WinAPI prototypes and enums from std.process. https://github.com/D-Programming-Language/phobos/commit/4e7cb93c44c1626c986b96b60dce7dcae934cc54 Merge pull request #1371 from AndrejMitrovic/Fix10469 Issue 10469 - Remove WinAPI prototypes and enums from std.process.