def arr.rep
import bend-toon-codec@0.1.0.0/src/encode.bend as Encodeimport Base
import bend-toon-codec@0.1.0.0/src/json.bend as J
import bend-toon-codec@0.1.0.0/src/rep.bend as R
252# An array's rep. `elem` is true for an element of another array, where the
253# tabular form is not available (section 9.4); `ls` is the encoding of the
254# elements as list items.
255def arr.rep(+elem: Bool, +items: J.Json, +d: Delim, +ls: R.Rep) -> R.Rep:
256 arr.pick(U32.is_zero(count(items)), all_prim(items), Bool.not(elem) && tabular(items), items, d, ls)