t7686.nim 152 B

1234567891011
  1. import std/strutils
  2. import std/assertions
  3. type
  4. MyEnum = enum
  5. A,
  6. a
  7. doAssert parseEnum[MyEnum]("A") == A
  8. doAssert parseEnum[MyEnum]("a") == a