12345678910111213141516171819202122232425262728 |
- discard """
- output: '''false'''
- """
- import macros
- type
- nlOptions = enum
- nloNone
- nloDebug
- var nlOpts {.compileTime.} = {nloDebug}
- proc initOpts(): set[nlOptions] =
- result.incl nloDebug
- result.incl nloNone
- result.excl nloDebug
- const cOpts = initOpts()
- macro nlo() =
- nlOpts.incl(nloNone)
- nlOpts.excl(nloDebug)
- result = newEmptyNode()
- nlo()
- echo nloDebug in cOpts
|