blob: 6655af977e44ff521e63e6fd48e61a4de0472e62 [file] [log] [blame]
SKIP: FAILED
#include <metal_stdlib>
using namespace metal;
struct S {
int a;
float b;
};
threadgroup S v;
kernel void tint_symbol(uint tint_local_index [[thread_index_in_threadgroup]]) {
if ((tint_local_index == 0u)) {
v = S{};
}
threadgroup_barrier(mem_flags::mem_threadgroup);
}
program_source:8:15: error: program scope variable must reside in constant address space
threadgroup S v;
^
program_source:10:25: warning: equality comparison with extraneous parentheses [-Wparentheses-equality]
if ((tint_local_index == 0u)) {
~~~~~~~~~~~~~~~~~^~~~~
program_source:10:25: note: remove extraneous parentheses around the comparison to silence this warning
if ((tint_local_index == 0u)) {
~ ^ ~
program_source:10:25: note: use '=' to turn this equality comparison into an assignment
if ((tint_local_index == 0u)) {
^~
=