diff options
| author | Yong He <yonghe@outlook.com> | 2024-07-30 20:28:34 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-07-30 20:28:34 -0700 |
| commit | 6e4b82741893be55f6216c31e19650029c667078 (patch) | |
| tree | fefd4529c6066763653732d7f93ca5cf07027a76 /tests/diagnostics | |
| parent | 04e7327a2067c82db3eaef51955f211e148ac933 (diff) | |
Fixes for Metal ParameterBlock support. (#4752)
Diffstat (limited to 'tests/diagnostics')
| -rw-r--r-- | tests/diagnostics/nested-constant-buffer-in-parameter-block.slang | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/tests/diagnostics/nested-constant-buffer-in-parameter-block.slang b/tests/diagnostics/nested-constant-buffer-in-parameter-block.slang new file mode 100644 index 000000000..eb9ecdd14 --- /dev/null +++ b/tests/diagnostics/nested-constant-buffer-in-parameter-block.slang @@ -0,0 +1,20 @@ +//TEST:SIMPLE(filecheck=CHECK): -target metal + +struct S +{ + // CHECK-DAG: ([[# @LINE+1]]): error 56100: + ConstantBuffer<int> cb; +} + +ParameterBlock<S> s; + +// CHECK-DAG: ([[# @LINE+1]]): error 56100: +ParameterBlock<ConstantBuffer<int>> s2; + +RWStructuredBuffer<int> outputBuffer; + +[numthreads(1,1,1)] +void kernelMain() +{ + outputBuffer[0] = s.cb + s2; +}
\ No newline at end of file |
