Mark Dickinson added the comment:

Thinking about it, `ValueError` seems like the right exception type: nothing's 
actually overflowing, because we haven't even tried to do any computation.  
This is just a limitation of what `math.factorial` is prepared to accept as 
input (and perhaps that limitation should be documented).

Here's a patch.  Bikeshedding about the exception type and the exception 
message is welcome.

----------
keywords: +patch
Added file: http://bugs.python.org/file33961/huge_factorial_input.patch

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue20539>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to