Index Mathematics Conjectures nbv lettuce Widgets

concat!

Join vectors end to end. Vectors

concat! a, b, ...

Concatenates one or more vectors in order. If every argument is static the result is static; if any argument is a witness, static arguments are lifted to constant witness entries and the result is a witness vector.

Arguments

a, b, ...
One or more expressions of any length, static or witness. Named variables are moved.

Returns

A vector whose length is the sum of the argument lengths. concat! is an expression.

Constraints

None. Lifting a static to a witness creates constant linear combinations, not witness entries.

Example

(let a, let b)
concat! a, [7 8], b

Notes

Arguments are separated by commas, so an argument that is itself a precompile invocation must be parenthesized: concat! (clone! a), slice(b, 0, 2). Function calls such as slice(...) need no parentheses.

Used in the standard library

bdlop/bdlop_lattice, bits/add32_bits, bits/rotl32_bits, bits/u32_bits_static, blake3/blake3_compress, blake3/blake3_core, blake3/blake3_g, blake3/blake3_rotate_rows, blake3/blake3_rotate_words, chacha/chacha_block, chacha/chacha_quarter_round, dilithium/lattice/lattice_permutation, ext/ext_eq_table, ext/ext_from_base, ext/ext_one, ext/ext_sum, ext/mle_eq_table, extend_to, keccak/keccak_f1600, keccak/keccak_sponge_shake, lattice/lattice_absorb, lattice/lattice_digest, lattice/lattice_expand, lattice/lattice_oraccle_commit, lattice/lattice_squeeze, mersenne61/poseidon/poseidon_mersenne61, milli/mldsa/mldsa_intt_sub, milli/mldsa/mldsa_ntt_z, milli/poseidon/poseidon_milli, mldsa/mldsa44_finish, mldsa/mldsa44_mu, mldsa/mldsa_expand_a, mldsa/mldsa_rej_ntt_poly, oraccle/oraccle_commit, oraccle/oraccle_sample_uniform_vec, oraccle/oraccle_squeeze, polynomial/mat_poly_compose_horizontal, polynomial/mat_poly_compose_vertical, polynomial/mat_poly_iden, polynomial/ntt_negacyclic_mat, r1cs/r1cs_compose_vertical, r1cs/r1cs_field_constraint, r1cs/r1cs_from_output, slip/slip_r1cs_arg_verify, typed/typed_bytes_lattice, typed/typed_lattice_digest_bits, typed/typed_lex_chacha