-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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] Variables initializer shouldn't be a reference #14584
Merged
webkit-commit-queue
merged 1 commit into
WebKit:main
from
tadeuzagallo:eng/WGSL-Variables-initializer-shouldnt-be-a-reference
Jun 5, 2023
Merged
[WGSL] Variables initializer shouldn't be a reference #14584
webkit-commit-queue
merged 1 commit into
WebKit:main
from
tadeuzagallo:eng/WGSL-Variables-initializer-shouldnt-be-a-reference
Jun 5, 2023
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
EWS run on previous version of this PR (hash 3e81c6a) |
mwyrzykowski
approved these changes
Jun 2, 2023
No reviewer information in commit message, blocking PR #14584 |
3e81c6a
to
b3d8654
Compare
EWS run on current version of this PR (hash b3d8654) |
https://bugs.webkit.org/show_bug.cgi?id=257601 rdar://110105334 Reviewed by Mike Wyrzykowski. When initializing a variable, the value used to initialize it should be unpacked if it's a reference. E.g.: var a = 0; var b = a; b = 1; The above program should not change the value of `a`, and references to `b` should have type `ref<i32>`, not `ref<ref<i32>>`. In order to fix that, when we infer the type of a variable initializer (which doesn't have an explicit type annotation), if the is a reference (as it would be for `a` in the example above, which would have type `ref<i32>`), we should use the referenced type instead (i.e. `i32` in this example) * Source/WebGPU/WGSL/TypeCheck.cpp: (WGSL::TypeChecker::visitVariable): Canonical link: https://commits.webkit.org/264860@main
b3d8654
to
e90fdfd
Compare
Committed 264860@main (e90fdfd): https://commits.webkit.org/264860@main Reviewed commits have been landed. Closing PR #14584 and removing active labels. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
e90fdfd
b3d8654
π§ͺ api-macπ§ͺ gtk-wk2π§ͺ mac-wk2π§ͺ mac-AS-debug-wk2