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

Redefinition error not enforced #437

Closed
therontarigo opened this issue Aug 10, 2024 · 2 comments
Closed

Redefinition error not enforced #437

therontarigo opened this issue Aug 10, 2024 · 2 comments

Comments

@therontarigo
Copy link
Contributor

Invalid Input

#version 450
out vec4 out_color;
void main () {
  float a = .1, b = .2, c = .3;
  float c = .4, b = .5;
  out_color = vec4(a, b, c, 1);
}

There is output when there should be an error:

#version 450
out vec4 out_color;
void main()
{
  out_color=vec4(.1,.5,.4,1);
}

With --no-inlining --no-remove-unused, there is broken output when there should be an error:

#version 450
out vec4 out_color;
void main()
{
  float a=.1,b=.2,c=.3,c=.4,b=.5;
  out_color=vec4(a,b,c,1);
}
@eldritchconundrum
Copy link
Collaborator

Shader Minifier emits errors when it cannot minify, but it intentionally doesn't verify that the shader is valid.
It assumes that the shader is valid.
This is so that it can just ignore the glsl/hlsl features that it does not understand, but still manage to minify them correctly sometimes.

@therontarigo
Copy link
Contributor Author

Indeed, and I have known this "bug" before and only bothered to report it this time to document it, since it appeared to confound a real bug, #436.
Closing as "won't fix".

@therontarigo therontarigo closed this as not planned Won't fix, can't repro, duplicate, stale Aug 11, 2024
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

No branches or pull requests

2 participants