Skip to content

types: Update FieldType.Equal safety.#841

Merged
kennytm merged 2 commits intopingcap:masterfrom
LittleFall:fix-float-flen-free
Apr 30, 2020
Merged

types: Update FieldType.Equal safety.#841
kennytm merged 2 commits intopingcap:masterfrom
LittleFall:fix-float-flen-free

Conversation

@LittleFall
Copy link
Contributor

What is changed and how it works?

This pr is a subsequent modification of parser/pull/832.

We find that when Decimal is specified, Flen will have a specific effect, see floating-point-types.

Current judgments can also cause problems.

This pr fixes it.

Check List

Tests

  • Integration test

Code changes

  • Has exported function/method change

@LittleFall LittleFall requested review from a team, Deardrops and wjhuang2016 April 28, 2020 10:46
@codecov
Copy link

codecov bot commented Apr 28, 2020

Codecov Report

Merging #841 into master will increase coverage by 0.09%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##           master     #841      +/-   ##
==========================================
+ Coverage   78.18%   78.28%   +0.09%     
==========================================
  Files          40       40              
  Lines       14638    14638              
==========================================
+ Hits        11445    11459      +14     
+ Misses       2512     2497      -15     
- Partials      681      682       +1     

Copy link
Contributor

@kennytm kennytm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please add a unit test for these equality rules.

Copy link
Contributor

@Deardrops Deardrops left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please add some tests

@LittleFall LittleFall force-pushed the fix-float-flen-free branch from 31228ba to e270d79 Compare April 30, 2020 06:12
@LittleFall LittleFall requested review from Deardrops and kennytm April 30, 2020 06:17
Copy link
Contributor

@Deardrops Deardrops left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Copy link
Contributor

@kennytm kennytm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@kennytm kennytm added the status/LGT2 LGT2 label Apr 30, 2020
@kennytm kennytm merged commit a1bca4f into pingcap:master Apr 30, 2020
@LittleFall LittleFall deleted the fix-float-flen-free branch May 6, 2020 04:53
tiancaiamao pushed a commit to tiancaiamao/parser that referenced this pull request Apr 27, 2021
* Fix float flen free bug.

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

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants