Skip to content

API: Allow weak promotion (NEP 50) as the only option - #25009

Closed
seberg wants to merge 2 commits into
numpy:mainfrom
seberg:always-weak
Closed

seberg wants to merge 2 commits into
numpy:mainfrom
seberg:always-weak

Conversation

@seberg

@seberg seberg commented Oct 26, 2023 •

Copy link
Copy Markdown
Member

This is a start of a cleanup, removing only the most obvious unused code chunks/paths. The main reasoning for doing this, is that it allows replacing further legacy code paths.
It would also make some experiments such as not converting incoming scalars to an array right away, feasible.
Some such experiments/optimizations are not possible as long as we need full legacy path support.

I would like to go with this because it is a big cleanup and allows further cleanups. It does however mean that one has to rely on numpy 1.26 if you want the "warning" option to get a sense of how much breakage there is or track down a change (and in some additional niche cases the warnings may be off with the final result due to fixes not backported).


(There is also a lot more related code, that is still relevant for niche public API Functions.)

This also fixes a cast for raw scalars, however, it seems unlikely
to affect code in practice (much or at all).
@seberg

seberg commented Nov 14, 2024

Copy link
Copy Markdown
Member Author

Oh, I hadn't realized that this was just ancient, and I already redid this later...

@seberg seberg closed this Nov 14, 2024
@seberg
seberg deleted the always-weak branch November 14, 2024 11:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant