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

[Issue 252] Add type cast for default enum values in C# #253

Merged
1 commit merged into from
Aug 12, 2015
Merged

[Issue 252] Add type cast for default enum values in C# #253

1 commit merged into from
Aug 12, 2015

Conversation

mormegil-cz
Copy link
Contributor

When creating a CreateXxx(...) method for a “simple table” type, enum-type fields with a non-zero default must have an explicit cast for the respective argument default value, because in C#, there is an implicit cast from int to an enum only for 0.

Also, added an example of such type into the example monster_test type, so that we test this feature.

When creating a �CreateXxx(...)� method for a �simple table� type,
enum-type fields with a non-zero default must have an explicit
cast for the respective argument default value, because in C#,
there is an implicit cast from int to an enum only for 0.

Also, added an example of such type into the example monster_test
type, so that we test this feature.
@ghost
Copy link

ghost commented Aug 12, 2015

Thanks for the fix!

ghost pushed a commit that referenced this pull request Aug 12, 2015
[Issue 252] Add type cast for default enum values in C#
@ghost ghost merged commit 9a1ab50 into google:master Aug 12, 2015
@mormegil-cz mormegil-cz deleted the issue-252 branch August 12, 2015 20:42
This pull request was closed.
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.

1 participant