the big renamefest: first steps

This commit is contained in:
Araq
2014-08-22 23:54:26 +02:00
parent 014b79617e
commit dbf9117c56
56 changed files with 529 additions and 508 deletions

View File

@@ -1,11 +1,13 @@
discard """
output: '''foobarfoobarbazbearbazbear'''
output: '''foobarfoobar
bazbearbazbear
1'''
cmd: "nimrod $target --threads:on $options $file"
"""
import threadpool
proc computeSomething(a, b: string): string = a & b & a & b
proc computeSomething(a, b: string): string = a & b & a & b & "\n"
proc main =
let fvA = spawn computeSomething("foo", "bar")
@@ -15,3 +17,19 @@ proc main =
main()
sync()
type
TIntSeq = seq[int]
proc t(): TIntSeq =
result = @[1]
proc p(): int =
var a: FlowVar[TIntSeq]
parallel:
var aa = spawn t()
a = aa
result = (^a)[0]
echo p()