tundeclaredmixin.nim 234 B

123456789101112131415161718
  1. discard """
  2. nimout: '''
  3. mixin nothing, add
  4. '''
  5. """
  6. # issue #22012
  7. import macros
  8. expandMacros:
  9. proc foo[T](): int =
  10. # `nothing` is undeclared, `add` is declared
  11. mixin nothing, add
  12. 123
  13. doAssert foo[int]() == 123