| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
requires that errno ever get set, and it looks like glibc is already
playing that game. New rules:
+ Never use HUGE_VAL. Use the new Py_HUGE_VAL instead.
+ Never believe errno. If overflow is the only thing you're interested in,
use the new Py_OVERFLOWED(x) macro. If you're interested in any libm
errors, use the new Py_SET_ERANGE_IF_OVERFLOW(x) macro, which attempts
to set errno the way C89 said it worked.
Unfortunately, none of these are reliable, but they work on Windows and I
*expect* under glibc too.
|
|
|
|
|
| |
platform. If it returns pi on the unixware7 platform, they have a bug in
their libm atan2.
|
| |
|
|
|
|
|
| |
Use != instead of <> since <> is documented as "obsolescent".
Use "is" and "is not" when comparing with None or type objects.
|
| |
|
|
|
|
|
| |
oddball platforms (where, e.g., math.exp(+huge) still fails to raise
OverflowError) don't fail the std test suite when run normally.
|
|
|
|
| |
changes. Here restoring them.
|
|
|
|
|
|
|
|
|
| |
libm result is 0). Cautiously add a few libm exception test cases:
1. That exp(-huge) returns 0 without exception.
2. That exp(+huge) triggers OverflowError.
3. That sqrt(-1) raises ValueError specifically (apparently under glibc linked
with -lieee, it was raising OverflowError due to an accident of the way
mathmodule.c's CHECK() macro happened to deal with Infs and NaNs under gcc).
|
|
|
|
| |
(and yes, "Currintly" also counts <0.5 wink>)
|
|
|
|
|
| |
Fix test of the "math" module so it does not break on platforms that do
not offer rint(); just skip that portion of the test in that case.
|
| |
|
|
|
|
| |
habits of the C library we happen to use...
|
|
|