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

[glsl-in] Validation failure with swizzle + inout argument #1621

Closed
fintelia opened this issue Dec 22, 2021 · 0 comments · Fixed by #1632
Closed

[glsl-in] Validation failure with swizzle + inout argument #1621

fintelia opened this issue Dec 22, 2021 · 0 comments · Fixed by #1632
Labels
area: front-end Input formats for conversion kind: bug Something isn't working lang: GLSL OpenGL Shading Language

Comments

@fintelia
Copy link
Contributor

This shader:

#version 450

void foo(inout vec2 p) {}

void main() {
    vec2 bar = vec2(1);
    foo(bar.xy);
}

Produces this error:

  ┌─ swizzle-inout.vert:5:1
  │
5 │ void main() {
  │ ^^^^^^^^^^^ naga::Function [2]
6 │     vec2 bar = vec2(1);
7 │     foo(bar.xy);
  │            ^^^ naga::Expression [8]

Function [2] 'main' is invalid: 
	The pointer [8] doesn't relate to a valid destination for a store
@kvark kvark added area: front-end Input formats for conversion kind: bug Something isn't working lang: GLSL OpenGL Shading Language labels Dec 22, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: front-end Input formats for conversion kind: bug Something isn't working lang: GLSL OpenGL Shading Language
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants