summary refs log blame commit diff stats
path: root/tests/js/tbasicenum.nim
blob: a9e9ce2dacb907832bf10aea0b6e9cf2364b316c (plain) (tree)
1
2
3
4
5
6
7
8
9
10









                                  
discard """
  output: "ABCDC"
"""

type
  MyEnum = enum
    A,B,C,D
# trick the optimizer with an seq:
var x = @[A,B,C,D]
echo x[0],x[1],x[2],x[3],MyEnum(2)