t8535.nim 258 B

1234567891011121314151617
  1. discard """
  2. output: "0"
  3. """
  4. type
  5. CircAlloc* [Size: static[int] , T] = tuple
  6. baseArray : array[Size,T]
  7. index : uint16
  8. type
  9. Job = object of RootObj
  10. var foo {.threadvar.}: CircAlloc[1,Job]
  11. when true:
  12. echo foo.index