Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Fix inconsistent behavior of Decimal.from_float #5411

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

Merged
merged 1 commit into from
Sep 22, 2024

Conversation

crazymerlyn
Copy link
Contributor

Rustpython includes the test added in python/cpython#65, but not the behavior, leading to the test being disabled. This patches RustPython with the above pr to update from_float behavior when passed an int in order to pass the test.

Copy link
Member

@coolreader18 coolreader18 left a comment

Choose a reason for hiding this comment

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

LGTM, thank you for contributing!

For posterity: this is updating _pydecimal to a newer version from CPython.

@coolreader18 coolreader18 merged commit eeb719e into RustPython:main Sep 22, 2024
11 checks passed
@crazymerlyn crazymerlyn deleted the decimal-from-float branch September 22, 2024 04:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants