Remove enum assignments and add [AssociatedEnum]
when the types don't align
#1572
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fixed #1502.
Fixed #1143.
The build will fail if an enum is assigned and the size or the sign don't match the original API.
Where the types of the enums could be changed to match the original API, I changed the type.
AssociatedEnum
contains the name of the associated enum which must exist in the same namespace as the API. All failures where the enum lived in the same namespace have been decorated with this attribute. Exceptions are below.I added an exception for functions that are remapped to return
WIN32_ERROR
but don't returnuint
. For scenarios where the associated enum lived in a different namespace than the API, this was the bulk of the APIs.Below are the rest of the APIs where the enums did not live in the same namespace as the API. I left them without an associated enum for now.