summaryrefslogtreecommitdiffstats
path: root/tests/language-feature/modules/wrapper-property.slang
blob: cfd9798b78725610b5f43353333dc60fba765230 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
//TEST:SIMPLE(filecheck=CHECK): -target spirv

//CHECK: OpEntryPoint

public interface ITest {
    public property int val;
};

public struct TestImpl : ITest {
    public int val;
}

public struct Test : ITest = TestImpl;

StructuredBuffer<Test> data;
RWStructuredBuffer<int> output;

[shader("compute")]
[numthreads(1,1,1)]
void computeMain()
{
    int val = data[0].val;
    output[0] = val;
}