blob: 3f9b28ba9031142c3ca9169feeffc0cff646165b (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
import Op, ValueStream, Input from require 'core.base'
str = ValueStream.meta
meta:
name: 'str'
summary: "Concatenate/stringify values."
examples: { '(.. v1 [v2…])', '(str v1 [v2…])' }
value: class extends Op
setup: (inputs) =>
@out or= ValueStream 'string'
super [Input.hot v for v in *inputs]
tick: =>
@out\set table.concat [tostring v! for v in *@inputs]
{
:str, '..': str
}
|