dawn-cmake/test/tint/statements/compound_assign/function.wgsl.expected.hlsl
James Price 508a9660a5 hlsl: Implement compound assignment
Use the ExpandCompoundAssignment transform to convert compound
assignments to regular assignments.

Bug: tint:1325
Change-Id: Ic843964ec24d8a2f00f801823f8f8bbf1c6fab5c
Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/85284
Reviewed-by: Ben Clayton <bclayton@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
2022-03-31 22:30:10 +00:00

14 lines
338 B
HLSL

[numthreads(1, 1, 1)]
void unused_entry_point() {
return;
}
void foo() {
int a = 0;
float4 b = float4(0.0f, 0.0f, 0.0f, 0.0f);
float2x2 c = float2x2(0.0f, 0.0f, 0.0f, 0.0f);
a = (a / 2);
b = mul(float4x4(0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f), b);
c = (c * 2.0f);
}