From a39123c93c9d2976300f1b8eba09d40b16f1c46c Mon Sep 17 00:00:00 2001 From: cooldome Date: Mon, 11 May 2020 22:11:20 +0100 Subject: fix #14219 (#14225) Co-authored-by: cooldome --- tests/arc/amodule.nim | 10 ++++++++++ tests/arc/tamodule.nim | 6 ++++++ 2 files changed, 16 insertions(+) create mode 100644 tests/arc/amodule.nim create mode 100644 tests/arc/tamodule.nim (limited to 'tests/arc') diff --git a/tests/arc/amodule.nim b/tests/arc/amodule.nim new file mode 100644 index 000000000..e853d0a77 --- /dev/null +++ b/tests/arc/amodule.nim @@ -0,0 +1,10 @@ +var vectors = @["a", "b", "c", "d", "e"] + +iterator testVectors(): string = + for vector in vectors: + yield vector + +var r = "" +for item in testVectors(): + r.add item +echo r \ No newline at end of file diff --git a/tests/arc/tamodule.nim b/tests/arc/tamodule.nim new file mode 100644 index 000000000..ac9757bd7 --- /dev/null +++ b/tests/arc/tamodule.nim @@ -0,0 +1,6 @@ +discard """ + output: "abcde" + cmd: "nim c --gc:arc $file" +""" + +import amodule -- cgit 1.4.1-2-gfad0