Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

gh-53032: support IEEE 754 contexts in the decimal module#122003

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
vstinner merged 15 commits intopython:mainfromskirpichev:expose-ieee_context-53032
Apr 28, 2025
Merged
Show file tree
Hide file tree
Changes from1 commit
Commits
Show all changes
15 commits
Select commitHold shift + click to select a range
b833af8
gh-53032: support IEEE 754 contexts in the decimal module
skirpichevJul 19, 2024
f25524d
Merge branch 'main' into expose-ieee_context-53032
skirpichevAug 20, 2024
ead16e4
Merge branch 'main' into expose-ieee_context-53032
skirpichevSep 25, 2024
7a34bb2
+ make lint happy
skirpichevSep 25, 2024
042d643
Apply suggestions from code review
skirpichevJan 24, 2025
75f7833
Merge branch 'master' into expose-ieee_context-53032
skirpichevJan 24, 2025
11dd047
address reviews
skirpichevJan 24, 2025
1b26d6f
Merge branch 'master' into expose-ieee_context-53032
skirpichevJan 24, 2025
4053dbb
address review: keep DECIMALXY in EXTRA_FUNCTIONALITY
skirpichevJan 24, 2025
3d016c9
Update Doc/library/decimal.rst
skirpichevJan 27, 2025
7caf3e5
Merge branch 'master' into expose-ieee_context-53032
skirpichevJan 27, 2025
35f7035
address review: drop OverflowError in Lib/_pydecimal.py
skirpichevJan 27, 2025
70cbbce
Merge branch 'master' into expose-ieee_context-53032
skirpichevFeb 15, 2025
1b8ede3
address review: add What's New entry
skirpichevFeb 15, 2025
702fb8c
Update Lib/_pydecimal.py
skirpichevApr 28, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
PrevPrevious commit
NextNext commit
address review: drop OverflowError in Lib/_pydecimal.py
  • Loading branch information
@skirpichev
skirpichev committedJan 27, 2025
commit35f70353d87ea1235614f89a029cc7e9a9d52a47
2 changes: 0 additions & 2 deletionsLib/_pydecimal.py
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -427,8 +427,6 @@ def IEEEContext(bits, /):
"""
import sys

if bits >= sys.maxsize:
raise OverflowError("Python int too large to convert to C ssize_t")
if bits <= 0 or bits > IEEE_CONTEXT_MAX_BITS or bits % 32:
raise ValueError("argument must be a multiple of 32, "
f"with a maximum of {IEEE_CONTEXT_MAX_BITS}")
Expand Down
1 change: 0 additions & 1 deletionLib/test/test_decimal.py
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -4417,7 +4417,6 @@ def assert_rest(self, context):
assert_rest(self, c)

# Invalid values
self.assertRaises(OverflowError, IEEEContext, sys.maxsize + 1)
self.assertRaises(ValueError, IEEEContext, -1)
self.assertRaises(ValueError, IEEEContext, 123)
self.assertRaises(ValueError, IEEEContext, 1024)
Expand Down
Loading

[8]ページ先頭

©2009-2025 Movatter.jp