Mercurial > repos > rhope
diff nworker_c.rhope @ 159:d1e206ff75f9
Fix some bugs involving calling a worker object
author | Mike Pavone <pavone@retrodev.com> |
---|---|
date | Fri, 07 Jan 2011 03:17:20 -0500 |
parents | 7bbdc034e347 |
children | 690ed78ead8a |
line wrap: on
line diff
--- a/nworker_c.rhope Thu Dec 23 16:16:31 2010 -0500 +++ b/nworker_c.rhope Fri Jan 07 03:17:20 2011 -0500 @@ -213,7 +213,7 @@ Wire From@NWorker Node[node,to,input,output:out] { existing cons <- [[node]Wires From >>]Index[output] {} - { exist cons <- () } + { existing cons <- () } out <- [node]Wires From <<[ [[node]Wires From >>]Set[output, [existing cons]Append[Node Ref[to,input]] @@ -1602,11 +1602,12 @@ Register Builtins@NProgram[prog:out] { - registered <- [[[[[[[[[[prog]Register Worker["Print", "rhope", 1, 1] + registered <- [[[[[[[[[[[prog]Register Worker["Print", "rhope", 1, 1] ]Register Worker["If@Boolean", "rhope", 1, 2] ]Register Worker["Build", "rhope", 1, 1] ]Register Worker["Blueprint Of", "rhope", 1, 1] - ]Register Worker["Call@Worker", "rhope", 1, 2] //We're using 2 because we need to assume that the outputs are conditional + ]Register Worker["Call", "rhope", 1, 1]//This will ensure that min outputs is 1 + ]Register Worker["Call@Worker", "rhope", 1, 10]//10 is a quick workaround for the lack of proper varargs ]Register Worker["ID", "rhope", 1, 1] ]Register Worker["Blueprint From ID", "rhope", 1, 2] ]Register Worker["Pause", "rhope", 1, 1] @@ -1645,7 +1646,7 @@ [[[[[NWorker["rhope"] ]Inputs <<[("worker")] ]Input Types <<[ [()]Append[Type Instance["Worker"]] ] - ]Outputs <<[("ret1","ret2")] + ]Outputs <<[("ret1","ret2","ret3","ret4","ret5","ret6","ret7","ret8","ret9","ret10")] ]Output Types <<[ [[()]Append[Type Instance["Any Type"]]]Append[Type Instance["Any Type"]] ] ]Builtin? << [Yes]] ]Bind Worker["ID",