You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Other Mono/.NET languages like C# allow enums to have a char data type instead of ints. Would be nice to do the same for Boo, or any other data types that are typical.
The text was updated successfully, but these errors were encountered:
That's interesting. I'd never heard of this before.
I just checked it out in C#, and it builds, but when I opened it in ILDasm, the enum field in question was typed as int32, not char, with its value being the ordinal value of the char. Seems like this is just the C# compiler magically making chars equal to ints, which kind of surprises me because I thought that that was one of the (many!) old, ugly C-isms that C# did away with.
I use enums all the time. its nice because the value can be somewhat readable (a is for apple,b is for bannana,c is for cucumber, etc.) for different options or correlate to something besides an integer. In my case, I'm looking to convert an enum from C# to Boo in unity.
Other Mono/.NET languages like C# allow enums to have a char data type instead of ints. Would be nice to do the same for Boo, or any other data types that are typical.
The text was updated successfully, but these errors were encountered: