summary refs log tree commit diff stats
path: root/tests/enum/tcrossmodule.nim
blob: c21072198ee877b20831f6e3b0c02ffb8e83eaf6 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
import mcrossmodule

type
  MyEnum = enum
    Success

template t =
  doAssert some(Success)

t()

block: # legacy support for behavior before overloadableEnums
  # warning: ambiguous enum field 'Success' assumed to be of type MyEnum
  let x = {Success}
  doAssert x is set[MyEnum]