-
Notifications
You must be signed in to change notification settings - Fork 5.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
expression: add new scalar function IsTruthWithNull #19621
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
PTAL @winoros @SunRunAway |
expression/builtin.go
Outdated
ast.UnaryMinus: &unaryMinusFunctionClass{baseFunctionClass{ast.UnaryMinus, 1, 1}}, | ||
ast.In: &inFunctionClass{baseFunctionClass{ast.In, 2, -1}}, | ||
ast.IsTruth: &isTrueOrFalseFunctionClass{baseFunctionClass{ast.IsTruth, 1, 1}, opcode.IsTruth, false}, | ||
ast.IsTruthWithNull: &isTrueOrFalseFunctionClass{baseFunctionClass{ast.IsTruthWithNull, 1, 1}, opcode.IsTruth, true}, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
By expanding AST, all places of use of ast.IsTruth
should also consider ast.IsTrueWithNull
.
Is expanding the function signature more suitable comparing to expanding AST?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think the two ways are same... Expanding AST is necessary, expanding the function signature is optional...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
PTAL @SunRunAway
Please resolve conflicts @wshwsh12 |
@wshwsh12 Please fix CI problems. |
/run-all-tests parser=pr/1016 |
/run-all-tests |
/run-unit-test |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
/run-unit-test |
1 similar comment
/run-unit-test |
Signed-off-by: ti-srebot <[email protected]>
cherry pick to release-3.0 in PR #19901 |
cherry pick to release-4.0 in PR #19903 |
What problem does this PR solve?
Issue Number: close #17720, close #17476
Problem Summary: NewFunction can't get keepnull attributes for isture function.
What is changed and how it works?
Proposal: xxx
What's Changed:
How it Works:
Related changes
Check List
Tests
Side effects
Release note