func Concat(frame wdte.Frame, args ...wdte.Func) wdte.Func {
	frame = frame.Sub("concat")
	if len(args) < 2 {
		return wdteutil.SaveArgs(wdte.GoFunc(Concat), args...)
	}
	var i int
	cur := args[0].(Stream)
	return NextFunc(func(frame wdte.Frame) (wdte.Func, bool) {
		if i >= len(args) {
			return nil, false
		}
		for {
			n, ok := cur.Next(frame)
			if !ok {
				i++
				if i >= len(args) {
					return nil, false
				}
				cur = args[i].(Stream)
				continue
			}
			return n, ok
		}
	})
}
Concat is a WDTE function with the following signatures:

concat s ...
(concat s) ...

It returns a new Stream that yields the values of all of its
argument Streams in the order that they were given.
package stream
import (
	"github.com/DeedleFake/wdte"
	"github.com/DeedleFake/wdte/wdteutil"
)
func New(frame wdte.Frame, args ...wdte.Func) wdte.Func {
	frame = frame.Sub("new")
	if len(args) < 2 {
		return wdteutil.SaveArgsReverse(wdte.GoFunc(New), args...)
	}
	prev := args[0]
	next := args[1]
	return NextFunc(func(frame wdte.Frame) (wdte.Func, bool) {
		if _, ok := prev.(end); ok {
			return nil, false
		}
		cur := prev
		prev = next.Call(frame, prev)
		return cur, true
	})
}
func Range(frame wdte.Frame, args ...wdte.Func) wdte.Func {
	frame = frame.Sub("range")
	if len(args) == 0 {
		return wdte.GoFunc(Range)
	}
	var i, m wdte.Number
	s := wdte.Number(1)
	switch len(args) {
	case 1:
		m = args[0].(wdte.Number)
	case 2:
		i = args[0].(wdte.Number)
		m = args[1].(wdte.Number)
		if i > m {
			s = -1
		}
	default:
		i = args[0].(wdte.Number)
		m = args[1].(wdte.Number)
		s = args[2].(wdte.Number)
	}
	return NextFunc(func(frame wdte.Frame) (wdte.Func, bool) {
		if (s >= 0) && (i >= m) {
			return nil, false
		}
		if (s < 0) && (i <= m) {
			return nil, false
		}
		n := i
		i += s
		return n, true
	})
}