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

dag: implement builtin UnaryMinus* #2202

Merged
merged 14 commits into from Aug 28, 2017

Conversation

Projects
None yet
4 participants
@choleraehyq

choleraehyq commented Aug 23, 2017

@andelf @hicqu @AndreMouche @BusyJay PTAL
Signed-off-by: Cholerae Hu huyingqian@pingcap.com

Cholerae Hu added some commits Aug 23, 2017

Cholerae Hu
dag: add unaryMinus*
Signed-off-by: Cholerae Hu <huyingqian@pingcap.com>
Cholerae Hu
dag: update fncall
Signed-off-by: Cholerae Hu <huyingqian@pingcap.com>
}
pub fn unary_minus_decimal(
&self,
pub fn unary_minus_decimal<'a, 'b: 'a>(

This comment has been minimized.

@andelf

andelf Aug 23, 2017

Contributor

why 'b outlives 'a?

@andelf

andelf Aug 23, 2017

Contributor

why 'b outlives 'a?

Cholerae Hu added some commits Aug 24, 2017

Cholerae Hu
dag: resolve conflict
Signed-off-by: Cholerae Hu <huyingqian@pingcap.com>

@choleraehyq choleraehyq requested review from AndreMouche, BusyJay and hicqu Aug 24, 2017

Cholerae Hu added some commits Aug 24, 2017

Cholerae Hu
expression: add unary_op overflow test
Signed-off-by: Cholerae Hu <huyingqian@pingcap.com>
Show outdated Hide outdated src/coprocessor/dag/expr/builtin_op.rs
if uval > i64::MAX as u64 + 1 {
return Err(Error::Overflow);
} else if uval == i64::MAX as u64 + 1 {
return Ok(Some(i64::MIN));

This comment has been minimized.

@BusyJay

BusyJay Aug 24, 2017

Contributor

Any test to cover this?

@BusyJay

BusyJay Aug 24, 2017

Contributor

Any test to cover this?

This comment has been minimized.

@choleraehyq
@choleraehyq
Cholerae Hu
expression: address comment
Signed-off-by: Cholerae Hu <huyingqian@pingcap.com>
Cholerae Hu
dag: fix unary_minus_int tests
Signed-off-by: Cholerae Hu <huyingqian@pingcap.com>
Cholerae Hu
dag: address comment
Signed-off-by: Cholerae Hu <huyingqian@pingcap.com>
@choleraehyq

This comment has been minimized.

Show comment
Hide comment
@choleraehyq

choleraehyq commented Aug 24, 2017

@AndreMouche

LGTM

@choleraehyq choleraehyq merged commit 9f19a2a into master Aug 28, 2017

2 checks passed

ci/circleci Your tests passed on CircleCI!
Details
license/cla Contributor License Agreement is signed.
Details

@choleraehyq choleraehyq deleted the hyq/unaryop branch Aug 28, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment