Add exact HigherOrderSignature#22326
Merged
gabotechs merged 4 commits intoMay 18, 2026
Merged
Conversation
This was referenced May 18, 2026
|
Thank you for opening this pull request! Reviewer note: cargo-semver-checks reported the current version number is not SemVer-compatible with the changes in this pull request (compared against the base branch). Details |
gabotechs
reviewed
May 18, 2026
Contributor
gabotechs
left a comment
There was a problem hiding this comment.
This looks good! just had a couple of questions
gabotechs
approved these changes
May 18, 2026
Contributor
gabotechs
left a comment
There was a problem hiding this comment.
Looks good! thanks @LiaCastaneda
Contributor
|
Thanks @LiaCastaneda! merging this one now. |
Contributor
Author
|
🤔 there is something going on with the merge queue |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Which issue does this PR close?
No issue — this is a follow-up to #21679.
Rationale for this change
In
ScalarUDF, arity is enforced by the framework viaTypeSignature. InHigherOrderUDF, functions with a fixed number of value and lambda arguments had to useUserDefinedand manually validate arity insidecoerce_value_types, which is boilerplate that every implementor has to repeat.What changes are included in this PR?
Adds
HigherOrderTypeSignature::Exact { values: usize, lambdas: usize }variant that enforces a fixed count of value and lambda arguments, calling coerce_value_types only for type coercion as wellAre these changes tested?
Yes I added some planning tests for exact siganture in
datafusion/expr/src/type_coercion/functions.rsAre there any user-facing changes?
Yes a new signature for HigherOrderSignature was added.