Skip to content

Unify promoter implementations and align behavior with NumPy - #120

Open
ngoldbaum wants to merge 3 commits into
numpy:mainfrom
ngoldbaum:fix-promoter-overlap
Open

Unify promoter implementations and align behavior with NumPy#120
ngoldbaum wants to merge 3 commits into
numpy:mainfrom
ngoldbaum:fix-promoter-overlap

Conversation

@ngoldbaum

@ngoldbaum ngoldbaum commented Sep 11, 2026

Copy link
Copy Markdown
Member

Fixes issues I noticed while looking over PR #118 today.

First, it unifies the promoter implementations to use a shared helper. Second, it updates the promoter logic to be more consistent with NumPy.

Currently, one can trigger errors due to ambiguous promotion. It's also not currently possible to do e.g. np.add(quad, quad, dtype='float64'). This fixes both issues. See the tests. I also deleted the existing promoter tests because they're duplicative with the new tests.

I used an AI model for help with this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant