t16639.nim 302 B

12345678910111213141516171819202122
  1. discard """
  2. action: compile
  3. """
  4. type Foo[T] = object
  5. when true:
  6. x: float
  7. type Bar = object
  8. when true:
  9. x: float
  10. import std/macros
  11. import std/assertions
  12. macro test() =
  13. let a = getImpl(bindSym"Foo")[^1]
  14. let b = getImpl(bindSym"Bar")[^1]
  15. doAssert treeRepr(a) == treeRepr(b)
  16. test()