-
Notifications
You must be signed in to change notification settings - Fork 221
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
Fixes renaming of enum options in dotnet #2874
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you also add unit tests for reserved keywords in other languages (at least Go and Java) so we know they are not unvoluntary escaped please?
It looks like other languages have the expectation of having the enum names replaced as their refiners do not pass an exclusion for the type with some existing tests for this. Java also has the expectation of name escaped captured in the test.
|
yes, this is probably a mistake that slept through but fixing it now would be a breaking change... |
I've updated Java,Php as they do not seem to have the keeping the enums names affected and the casing will be changed on writing. Go is hold for now. Python has reserved keywords like |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not having typescript should be fine since enum values are lowercased and more likely to conflict with language keywords
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for making the changes!
SonarCloud Quality Gate failed. 0 Bugs 69.2% Coverage Catch issues before they fail your Quality Gate with our IDE extension SonarLint |
CodeEnumOption
was recently changed to derive fromCodeElement
and therefore lead to changing(double processing) of the type in theReplaceReservedNames
function in theCommonLanguageRefiner
.This Pr streamlines the handling of the
CodeEnumOption
type to be handled like otherCodeElement
instances and adds tests to validate.