Skip to content

Sema: check min/max operand types #24062

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

JackoCoolio
Copy link

We weren't checking the types of operands after the first, and then later we were assuming they were all numeric.

Closes #24060.

We weren't checking the types of operands after the first,
and then later we were assuming they were all numeric.

Closes ziglang#24060.
@alexrp alexrp requested a review from mlugg June 3, 2025 02:17
@Rexicon226
Copy link
Contributor

Needs tests! They should be placed in test/cases/compile_errors/.

@nektro
Copy link
Contributor

nektro commented Jun 3, 2025

can you add cases to that file for the other types as well?
and add a file testing @max?

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.

@max crashes compiler for incompatible argument types
3 participants