MCPcopy Create free account
hub / github.com/apache/datafusion / array_prepend_inner

Function array_prepend_inner

datafusion/functions-nested/src/concat.rs:464–472  ·  view source on GitHub ↗
(args: &[ArrayRef])

Source from the content-addressed store, hash-verified

462}
463
464fn array_prepend_inner(args: &[ArrayRef]) -> Result<ArrayRef> {
465 let [values, array] = take_function_args("array_prepend", args)?;
466 match array.data_type() {
467 DataType::Null => make_array_inner(&[Arc::clone(values)]),
468 DataType::List(_) => general_append_and_prepend::<i32>(args, false),
469 DataType::LargeList(_) => general_append_and_prepend::<i64>(args, false),
470 arg_type => exec_err!("array_prepend does not support type {arg_type}"),
471 }
472}
473
474fn general_append_and_prepend<O: OffsetSizeTrait>(
475 args: &[ArrayRef],

Callers

nothing calls this directly

Calls 3

take_function_argsFunction · 0.85
make_array_innerFunction · 0.70
data_typeMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…