We are currently migrating Bugzilla to GitHub issues.
Any changes made to the bug tracker now will be lost, so please do not post new bugs or make changes to them.
When we're done, all bug URLs will redirect to their equivalent location on the new bug tracker.

Bug 4813

Summary: Please give all enums their own name
Product: SDL Reporter: Lokathor <zefria>
Component: *don't know*Assignee: Ryan C. Gordon <icculus>
Status: RESOLVED FIXED QA Contact: Sam Lantinga <slouken>
Severity: trivial    
Priority: P2 CC: sylvain.becker
Version: don't knowKeywords: target-2.0.12
Hardware: All   
OS: All   

Description Lokathor 2019-10-02 21:52:51 UTC
In 2.0.10, the `SDL_PIXELFORMAT_foo` enum was changed from a bare enum definition without a name into `typedef enum { ... } SDL_PixelFormatEnum`.

This is a very good change for people in other languages using automated bindings generation to call into SDL2. I would like to request that you also make the same small adjustment for the other enums that don't currently have their own dedicated name:

* SDL_PIXELTYPE_
* SDL_BITMAPORDER_
* SDL_PACKEDORDER_
* SDL_ARRAYORDER_
* SDL_PACKEDLAYOUT_
* SDLK_
* SDL_LOG_CATEGORY_
Comment 1 Ryan C. Gordon 2019-10-08 18:15:03 UTC
Gonna try to sneak this into 2.0.12 if there's time.

--ryan.
Comment 2 Sylvain 2019-10-10 15:42:19 UTC
I found some time :)
That was done for SDL_PixelFormatEnum here:
https://hg.libsdl.org/SDL/rev/b590d04d5cf7

and here's the others:
https://hg.libsdl.org/SDL/rev/28c572567380


SDLK_ enum is named SDL_KeyCodeEnum
others:
SDL_LogCategoryEnum
SDL_PixelTypeEnum
SDL_BitmapOrderEnum
SDL_PackedOrderEnum
SDL_ArrayOrderEnum
SDL_PackedLayoutEnum
Comment 3 Sylvain 2019-10-11 04:22:04 UTC
Remove 'Enum' suffixes
https://hg.libsdl.org/SDL/rev/4cbaffd0083b