summaryrefslogtreecommitdiff
path: root/tests/parser/cast-precedence.hlsl
blob: 3383d9912e542afdfb8803df16b60dca0c43385d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
//TEST:COMPARE_HLSL: -profile vs_5_0

// Confirm that type-cast expressions parse with
// the appropriate precedence.

#ifndef __SLANG__
#define C C_0
#define a a_0
#define b b_0
#define SV_Position SV_POSITION
#endif

cbuffer C : register(b0)
{
	float a;
	float b;
};

float4 main() : SV_Position
{
	return (uint) a / b;
}