Skip to content

BUG: Force `npymath to respect npy_longdouble`#20465

Merged
charris merged 1 commit intonumpy:maintenance/1.21.xfrom
charris:backport-20360
Nov 26, 2021
Merged

BUG: Force `npymath to respect npy_longdouble`#20465
charris merged 1 commit intonumpy:maintenance/1.21.xfrom
charris:backport-20360

Conversation

@charris
Copy link
Copy Markdown
Member

@charris charris commented Nov 25, 2021

Backport of #20360.

Revert from long double changes and force npymath to respect npy_longdouble.

In some certain cases mostly workarounds, there's a necessity to define npy_longdouble
as double even if that was against the compiler implementation(sizeof(long double) != sizeof(double)).

Therefore, avoid long double, use npy_longdouble instead,
and when it comes to standard math functions make sure of using
the double version when NPY_SIZEOF_LONGDOUBLE == NPY_SIZEOF_DOUBLE.

Closes #20348

…t `npy_longdouble` (numpy#20360)

In some certain cases mostly workarounds, there's a necessity to define `npy_longdouble`
as `double` even if that was against the compiler
implementation(sizeof(long double) != sizeof(double)).

Therefore, avoid `long double`, use `npy_longdouble` instead,
and when it comes to standard math functions make sure of using
the double version when `NPY_SIZEOF_LONGDOUBLE` == `NPY_SIZEOF_DOUBLE`.
@charris charris added 00 - Bug 08 - Backport Used to tag backport PRs labels Nov 25, 2021
@charris charris added this to the 1.21.5 release milestone Nov 25, 2021
@charris charris merged commit e1fe715 into numpy:maintenance/1.21.x Nov 26, 2021
@charris charris deleted the backport-20360 branch November 26, 2021 01:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

00 - Bug 08 - Backport Used to tag backport PRs

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants