Guest User

Untitled

a guest
Aug 17th, 2018
80
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.22 KB | None | 0 0
  1. Why can't I base an enum off UInt16?
  2. static void Main()
  3. {
  4. Console.WriteLine(typeof(MyEnum).BaseType.FullName);
  5. }
  6.  
  7. enum MyEnum : ushort
  8. {
  9. One = 1,
  10. Two = 2
  11. }
  12.  
  13. enum MyEnum : UInt16
  14. {
  15. One = 1,
  16. Two = 2
  17. }
Add Comment
Please, Sign In to add comment