tnewseq_legacy.nim 258 B

1234567891011121314
  1. discard """
  2. output: "(allocCount: 201, deallocCount: 201)"
  3. cmd: "nim c --gc:orc -d:nimAllocStats $file"
  4. """
  5. proc main(prefix: string) =
  6. var c: seq[string]
  7. for i in 0..<100:
  8. newSeq(c, 100)
  9. c[i] = prefix & $i
  10. main("abc")
  11. echo getAllocStats()