summaryrefslogtreecommitdiff
path: root/tests/diagnostics/syntax-error-op-line.slang
blob: eab15e4a494b8a7f7a12b3dd546ae8743a52f881 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
// syntax-error-op-line.slang

// NOTE! That although this is a 'diagnostic' like test, it tests using downstream compiler
// the downstream compiler being present is a requirement, so we mark as a 'TEST' so that 
// those tests are made.

//TEST:SIMPLE_LINE:-entry computeMain -target spirv 
//TEST:SIMPLE_LINE:-entry computeMain -target dxil -profile cs_6_0 
//TEST:SIMPLE_LINE:-entry computeMain -target dxbc 
//TEST:SIMPLE_LINE:-entry computeMain -target dll 
//TEST:SIMPLE_LINE:-entry computeMain -target ptx 

[shader("compute")]
[numthreads(4, 1, 1)]
void computeMain(uint3 dispatchThreadID : SV_DispatchThreadID)
{
    int id = int(dispatchThreadID.x);
    
    int v = int(dispatchThreadID.y);
    
    v += id + __SyntaxError();
}