mirror of
https://github.com/encounter/dawn-cmake.git
synced 2025-08-05 11:45:54 +00:00
Involves expanding the source range of a variable declaration so we can point at something that can include the 'const'. Fixed: tint:1740 Change-Id: Ie8f784de34a1792002aaa708c1b77053be54f1b5 Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/108120 Kokoro: Kokoro <noreply+kokoro@google.com> Reviewed-by: David Neto <dneto@google.com> Commit-Queue: Ben Clayton <bclayton@google.com>
24 lines
494 B
GLSL
24 lines
494 B
GLSL
bug/tint/1474-b.wgsl:7:5 warning: code is unreachable
|
|
let non_uniform_cond = non_uniform_value == 0;
|
|
^^^^^^^^^^^^^^^^^^^^
|
|
|
|
#version 310 es
|
|
|
|
layout(binding = 0, std430) buffer non_uniform_value_block_ssbo {
|
|
int inner;
|
|
} non_uniform_value;
|
|
|
|
void tint_symbol() {
|
|
return;
|
|
bool non_uniform_cond = (non_uniform_value.inner == 0);
|
|
if (non_uniform_cond) {
|
|
barrier();
|
|
}
|
|
}
|
|
|
|
layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
|
|
void main() {
|
|
tint_symbol();
|
|
return;
|
|
}
|