timportedtypecrash.nim 299 B

12345678910111213141516
  1. discard """
  2. action: compile
  3. targets: "cpp"
  4. matrix: "--compileOnly"
  5. """
  6. # issue #20065
  7. type
  8. Foo* {.importC, nodecl.} = object # doesn't matter if this is importC or importCpp
  9. value*: int64
  10. Bar* {.importCpp, nodecl.} = object # no segfault with importC
  11. foo*: Foo
  12. discard @[Bar()]