summary refs log blame commit diff stats
path: root/tests/accept/compile/tenum2.nim
blob: feba36dd69519b14a558b338211f2d1ddd459fb6 (plain) (tree)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16















                                                                  
# Test that enum with holes is handled correctly by case statement

type
  TEnumHole = enum 
    eA = 0,
    eB = 4,
    eC = 5
    
var
  e: TEnumHole = eB
  
case e
of eA: echo "A"
of eB: echo "B"
of eC: echo "C"