8000 Fix incorrect error type in math.factorial documentation (GH-133904) by abhigyan631 · Pull Request #133913 · python/cpython · GitHub
[go: up one dir, main page]

Skip to content

Fix incorrect error type in math.factorial documentation (GH-133904) #133913

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

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
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
4 changes: 2 additions & 2 deletions Doc/library/math.rst
Original file line number Diff line number Diff line change
Expand Up @@ -144,8 +144,8 @@ Number-theoretic functions

.. function:: factorial(n)

Return *n* factorial as an integer. Raises :exc:`ValueError` if *n* is not integral or
is negative.
Return *n* factorial as an integer. Raises :exc:`TypeError` if *n* is not an integer.
Raises :exc:`ValueError` if *n* is negative.

.. versionchanged:: 3.10
Floats with integral values (like ``5.0``) are no longer accepted.
Expand Down
3 changes: 2 additions & 1 deletion Modules/clinic/mathmodule.c.h

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading
0