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

[naga] Handle validation should check array size override initializer handles too #6880

Closed
jimblandy opened this issue Jan 8, 2025 · 0 comments · Fixed by #6882
Closed
Labels
area: naga middle-end Intermediate representation area: validation Issues related to validation, diagnostics, and error handling naga Shader Translator

Comments

@jimblandy
Copy link
Member

jimblandy commented Jan 8, 2025

As pointed out in #6800 (comment), handle validation should check the override handle h in PendingArraySize::Override(h), too.

@cwfitzgerald cwfitzgerald added area: validation Issues related to validation, diagnostics, and error handling naga Shader Translator area: naga middle-end Intermediate representation labels Jan 8, 2025
jimblandy added a commit to jimblandy/wgpu that referenced this issue Jan 8, 2025
When an array type `A`'s size is `PendingArraySize::Override(h)`,
verify that:

- `h` is a valid override handle,

- the override's type precedes `A` in the type arena, and

- the override's expression does not participate in a type/global
  expression cycle.

Fixes gfx-rs#6880.
github-merge-queue bot pushed a commit that referenced this issue Jan 9, 2025
When an array type `A`'s size is `PendingArraySize::Override(h)`,
verify that:

- `h` is a valid override handle,

- the override's type precedes `A` in the type arena, and

- the override's expression does not participate in a type/global
  expression cycle.

Fixes #6880.
@github-project-automation github-project-automation bot moved this from Todo to Done in WebGPU for Firefox Jan 9, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: naga middle-end Intermediate representation area: validation Issues related to validation, diagnostics, and error handling naga Shader Translator
Projects
Status: Done
Development

Successfully merging a pull request may close this issue.

2 participants