lang: core: iter: Misc formatting fixes
Also fix up the examples.
This commit is contained in:
@@ -10,4 +10,4 @@ $out1 = iter.map($in1, $fn)
|
||||
|
||||
$t1 = template("out1: {{ . }}", $out1)
|
||||
|
||||
test $t1 {}
|
||||
test [$t1,] {}
|
||||
|
||||
@@ -25,4 +25,4 @@ $out1 = iter.map($in1, $fn)
|
||||
|
||||
$t1 = template("out1: {{ . }}", $out1)
|
||||
|
||||
test $t1 {}
|
||||
test [$t1,] {}
|
||||
|
||||
@@ -37,7 +37,7 @@ $out1 = iter.map($in1, $fn)
|
||||
|
||||
$t1 = template("out1: {{ . }}", $out1)
|
||||
|
||||
test $t1 {}
|
||||
test [$t1,] {}
|
||||
|
||||
file "/tmp/mgmt/map" {
|
||||
state => $const.res.file.state.exists,
|
||||
|
||||
@@ -343,7 +343,8 @@ func (obj *MapFunc) Stream(ctx context.Context) error {
|
||||
|
||||
func (obj *MapFunc) replaceSubGraph(subgraphInput interfaces.Func) error {
|
||||
// Create a subgraph which splits the input list into 'n' nodes, applies
|
||||
// 'newFuncValue' to each, then combines the 'n' outputs back into a list.
|
||||
// 'newFuncValue' to each, then combines the 'n' outputs back into a
|
||||
// list.
|
||||
//
|
||||
// Here is what the subgraph looks like:
|
||||
//
|
||||
@@ -356,9 +357,9 @@ func (obj *MapFunc) replaceSubGraph(subgraphInput interfaces.Func) error {
|
||||
// "inputElemFunc1" -> "outputElemFunc1"
|
||||
// "inputElemFunc2" -> "outputElemFunc2"
|
||||
//
|
||||
// "outputElemFunc0" -> "outputListFunc"
|
||||
// "outputElemFunc1" -> "outputListFunc"
|
||||
// "outputElemFunc1" -> "outputListFunc"
|
||||
// "outputElem0" -> "outputListFunc"
|
||||
// "outputElem1" -> "outputListFunc"
|
||||
// "outputElem2" -> "outputListFunc"
|
||||
//
|
||||
// "outputListFunc" -> "subgraphOutput"
|
||||
// }
|
||||
|
||||
Reference in New Issue
Block a user