Bug 15322 – version(Unicode) should affect only default aliases

Status
RESOLVED
Resolution
FIXED
Severity
normal
Priority
P1
Component
druntime
Product
D
Version
D2
Platform
All
OS
Windows
Creation time
2015-11-12T08:27:31Z
Last change time
2020-02-06T05:11:26Z
Keywords
pull
Assigned to
No Owner
Creator
anonymous4

Comments

Comment #0 by dfj1esp02 — 2015-11-12T08:27:31Z
If version(Unicode) is not defined, windows bindings should still have unicode declarations. Declaration of PENUM_PAGE_FILE_CALLBACK in psapi is incorrectly versioned, as a consequence unicode function EnumPageFilesW is declared as taking ANSI callback. Unicode and ANSI versions of PENUM_PAGE_FILE_CALLBACK (PENUM_PAGE_FILE_CALLBACKW and PENUM_PAGE_FILE_CALLBACKA respectively) should be declared unconditionally and PENUM_PAGE_FILE_CALLBACK alias should be versioned.
Comment #1 by dlang-bot — 2020-02-04T01:34:38Z
@LimiQS created dlang/druntime pull request #2928 "Fix Issue 15322 - Correct versioning PENUM_PAGE_FILE_CALLBACK" fixing this issue: - Fix Issue 15322 - Correct versioning PENUM_PAGE_FILE_CALLBACK According to [Microsoft Docs](https://docs.microsoft.com/en-us/windows/win32/api/psapi/nf-psapi-enumpagefilesw), `EnumPageFilesW` always taking a `PENUM_PAGE_FILE_CALLBACKW` parameter. While before the correction, when version `Unicode` is not defined, `EnumPageFilesW` will be declared to take a `PENUM_PAGE_FILE_CALLBACKW`. https://github.com/dlang/druntime/pull/2928
Comment #2 by dlang-bot — 2020-02-06T05:11:26Z
dlang/druntime pull request #2928 "Fix Issue 15322 - Correct versioning PENUM_PAGE_FILE_CALLBACK" was merged into master: - 515500355fde5d1611e751163f0c79bfdd78f19c by Asakusa Yakumo: Fix Issue 15322 - Correct versioning PENUM_PAGE_FILE_CALLBACK According to [Microsoft Docs](https://docs.microsoft.com/en-us/windows/win32/api/psapi/nf-psapi-enumpagefilesw), `EnumPageFilesW` always taking a `PENUM_PAGE_FILE_CALLBACKW` parameter. While before the correction, when version `Unicode` is not defined, `EnumPageFilesW` will be declared to take a `PENUM_PAGE_FILE_CALLBACKW`. https://github.com/dlang/druntime/pull/2928