Skip to content

Commit 153b38f

Browse files
committed
review: correct the check of MaxAnisotropy
1 parent 4a2761d commit 153b38f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

clang/lib/Sema/SemaHLSL.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1145,7 +1145,7 @@ bool SemaHLSL::handleRootSignatureElements(
11451145
"By construction, parseFloatParam can't produce a NaN from a "
11461146
"float_literal token");
11471147

1148-
if (16 < Sampler->MaxAnisotropy)
1148+
if (!llvm::hlsl::rootsig::verifyMaxAnisotropy(Sampler->MaxAnisotropy))
11491149
ReportError(Loc, 0, 16);
11501150
if (!llvm::hlsl::rootsig::verifyMipLODBias(Sampler->MipLODBias))
11511151
ReportFloatError(Loc, -16.f, 15.99);

0 commit comments

Comments
 (0)