shithub: mc

ref: 9892228031c0ffcfa95a1443fc565b031525bb3a
dir: /lib/std/sldup.myr/

View raw version
use "alloc"
use "die"
use "slcp"

pkg std =
	generic sldup : (sl : @a[:] -> @a[:])
;;

generic sldup = {sl
	var ret

	ret = slalloc(sl.len)
	slcp(ret, sl)
	-> ret
}