Fix signatures for cellpath access of records (#9793)

# Description
The same procedure as for #9778 repeated for records.

# User-Facing Changes
Commands that directly supported applying their work directly to record
fields via cell paths, that worked before #9680 will now work again

# Tests + Formatting
Tried to limit the need to add new `.allow_variants_without_examples()`
by adjusting or adding tests to also use some records with access.
This commit is contained in:
Stefan Holderbach
2023-07-26 23:13:57 +02:00
committed by GitHub
parent f8d325dbfe
commit d9230a76f3
47 changed files with 95 additions and 21 deletions

View File

@ -42,7 +42,12 @@ impl Command for SubCommand {
fn signature(&self) -> Signature {
Signature::build("str substring")
.input_output_types(vec![(Type::String, Type::String), (Type::List(Box::new(Type::String)), Type::List(Box::new(Type::String))), (Type::Table(vec![]), Type::Table(vec![]))])
.input_output_types(vec![
(Type::String, Type::String),
(Type::List(Box::new(Type::String)), Type::List(Box::new(Type::String))),
(Type::Table(vec![]), Type::Table(vec![])),
(Type::Record(vec![]), Type::Record(vec![])),
])
.vectorizes_over_list(true)
.allow_variants_without_examples(true)
.switch(