D issues are now tracked on GitHub. This Bugzilla instance remains as a read-only archive.
Issue 15322 - version(Unicode) should affect only default aliases
Summary: version(Unicode) should affect only default aliases
Status: RESOLVED FIXED
Alias: None
Product: D
Classification: Unclassified
Component: druntime (show other issues)
Version: D2
Hardware: All Windows
: P1 normal
Assignee: No Owner
URL: https://msdn.microsoft.com/en-us/libr...
Keywords: pull
Depends on:
Blocks:
 
Reported: 2015-11-12 08:27 UTC by anonymous4
Modified: 2020-02-06 05:11 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this issue.
Description anonymous4 2015-11-12 08:27:31 UTC
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 Dlang Bot 2020-02-04 01:34:38 UTC
@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 Dlang Bot 2020-02-06 05:11:26 UTC
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