tenum_self.nim 140 B

123456789101112
  1. discard """
  2. errormsg: "1 can't be converted to ErrorFoo"
  3. """
  4. type
  5. Foo = enum
  6. Bar = 0.Foo
  7. ErrorFoo = enum
  8. eBar = 1.ErrorFoo