Skip to content

feat: support case style macros (@PascalCase, @SnakeCase, etc.) on enums#38

Merged
vnixx merged 1 commit intomainfrom
name_case_conversion_for_enum
Feb 28, 2026
Merged

feat: support case style macros (@PascalCase, @SnakeCase, etc.) on enums#38
vnixx merged 1 commit intomainfrom
name_case_conversion_for_enum

Conversation

@vnixx
Copy link
Member

@vnixx vnixx commented Feb 28, 2026

Allow naming convention macros to be applied at the enum level and individual enum case level, automatically converting case names for encoding/decoding. Decoding accepts a union of all applicable values (many-to-one), encoding uses the highest priority value.

Priority order: @CodingCase > explicit rawValue > case-level style >
enum-level style > caseName fallback.

Constraints: @CodingCase with 'at:' or 'values:' parameter cannot coexist with case style macros. Numeric raw type enums are also disallowed.

Closes #36

Made-with: Cursor

Allow naming convention macros to be applied at the enum level and
individual enum case level, automatically converting case names for
encoding/decoding. Decoding accepts a union of all applicable values
(many-to-one), encoding uses the highest priority value.

Priority order: @CodingCase > explicit rawValue > case-level style >
enum-level style > caseName fallback.

Constraints: @CodingCase with 'at:' or 'values:' parameter cannot
coexist with case style macros. Numeric raw type enums are also
disallowed.

Closes #36

Made-with: Cursor
@vnixx vnixx merged commit e4f297a into main Feb 28, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

@CodingCase is inconsistent between decoding and encoding

1 participant