Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

When generating java code, enum values starting with digits will be replaced with VALUE_x #1819

Open
TheMinefighter opened this issue Oct 14, 2024 · 0 comments

Comments

@TheMinefighter
Copy link

Any enum that contains at least one value which start with e.g. a digit will have all of it's values renamed to VALUE_x in java code generation. That should not happen. Instead an underscore should be added to create a valid java identifier, as it is done at other places in the java code generation too: a package called 12 will be called _12 in generated java code. That should also apply to enum values.

TheMinefighter added a commit to TheMinefighter/jaxb-ri that referenced this issue Oct 14, 2024
… leading digits

The first character of an enum value name is checked whether it complies with isJavaIdentifierStart, if not an underscore prefix will be added to that name.
TheMinefighter added a commit to TheMinefighter/jaxb-ri that referenced this issue Oct 14, 2024
… leading digits

The first character of an enum value name is checked whether it complies with isJavaIdentifierStart, if not an underscore prefix will be added to that name.
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

No branches or pull requests

1 participant