Skip to content
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

wgsl: signedness mismatch fixes #5692

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

Conversation

aleino-nv
Copy link
Collaborator

Add some missing integer type conversions to legalize WGSL code.
I believe the issues fixed here are typically handled by implicit conversions in less strict languages.
WGSL, however, requires us to emit explicit casts in these cases.

This closes #5606

@aleino-nv aleino-nv requested a review from a team as a code owner November 27, 2024 09:31
@aleino-nv aleino-nv added the pr: non-breaking PRs without breaking changes label Nov 27, 2024
@aleino-nv
Copy link
Collaborator Author

/format

@slangbot
Copy link
Contributor

🌈 Formatted, please merge the changes from this PR

aleino-nv added a commit to aleino-nv/slang that referenced this pull request Nov 27, 2024
@aleino-nv aleino-nv enabled auto-merge (squash) November 27, 2024 09:33
This fixes signedness mismatch issues for:
- Binary operators
- Return values

This closes shader-slang#5606.
@aleino-nv aleino-nv force-pushed the aleino/wgsl-signedness-mismatch-fixes branch from a68ec83 to 3b439d3 Compare November 27, 2024 10:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pr: non-breaking PRs without breaking changes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

WGSL: No matching overload for operator...
2 participants