@@ -1361,7 +1361,7 @@ bool SemaHLSL::handleRootSignatureElements(
13611361 bool HasAnySampler = false ;
13621362 bool HasAnyNonSampler = false ;
13631363 uint64_t Offset = 0 ;
1364- bool Unbound = false ;
1364+ bool IsPrevUnbound = false ;
13651365 for (const auto &[Clause, ClauseElem] : UnboundClauses) {
13661366 SourceLocation Loc = ClauseElem->getLocation ();
13671367 if (Clause->Type == llvm::dxil::ResourceClass::Sampler)
@@ -1386,15 +1386,15 @@ bool SemaHLSL::handleRootSignatureElements(
13861386 uint64_t RangeBound = llvm::hlsl::rootsig::computeRangeBound (
13871387 Offset, Clause->NumDescriptors );
13881388
1389- if (Unbound && IsAppending)
1389+ if (IsPrevUnbound && IsAppending)
13901390 Diag (Loc, diag::err_hlsl_appending_onto_unbound);
13911391 else if (!llvm::hlsl::rootsig::verifyNoOverflowedOffset (RangeBound))
13921392 Diag (Loc, diag::err_hlsl_offset_overflow) << Offset << RangeBound;
13931393
13941394 // Update offset to be 1 past this range's bound
13951395 Offset = RangeBound + 1 ;
1396- Unbound = Clause->NumDescriptors ==
1397- llvm::hlsl::rootsig::NumDescriptorsUnbounded;
1396+ IsPrevUnbound = Clause->NumDescriptors ==
1397+ llvm::hlsl::rootsig::NumDescriptorsUnbounded;
13981398
13991399 // Compute the register bounds and track resource binding
14001400 uint32_t LowerBound (Clause->Reg .Number );
0 commit comments