Debian Codegraph @

third_party/spirv-cross/reference/shaders-msl-no-opt/asm/frag/empty-struct-in-struct.asm.frag

raw
1 #pragma clang diagnostic ignored "-Wmissing-prototypes"
2
3 #include <metal_stdlib>
4 #include <simd/simd.h>
5
6 using namespace metal;
7
8 struct EmptyStructTest
9 {
10 };
11 struct EmptyStruct2Test
12 {
13 EmptyStructTest _m0;
14 };
15
16 static inline __attribute__((always_inline))
17 float GetValue(thread const EmptyStruct2Test& self)
18 {
19 return 0.0;
20 }
21
22 static inline __attribute__((always_inline))
23 float GetValue_1(EmptyStruct2Test self)
24 {
25 return 0.0;
26 }
27
28 fragment void main0()
29 {
30 EmptyStruct2Test emptyStruct;
31 float value = GetValue(emptyStruct);
32 value = GetValue_1(EmptyStruct2Test{ EmptyStructTest{ } });
33 value = GetValue_1(EmptyStruct2Test{ { } });
34 }
35