[ClangCL] fix clang-cl build warning. (#6492)
Fix sign-compare warnings.
This commit is contained in:
Родитель
27b87b7593
Коммит
8322cabfc0
|
@ -98,7 +98,8 @@ bool IsValidDxilContainer(const DxilContainerHeader *pHeader, size_t length) {
|
||||||
}
|
}
|
||||||
|
|
||||||
// Container size should match end of last part
|
// Container size should match end of last part
|
||||||
if (nextPartBegin - pLinearContainer != pHeader->ContainerSizeInBytes)
|
if ((uint32_t)(nextPartBegin - pLinearContainer) !=
|
||||||
|
pHeader->ContainerSizeInBytes)
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
|
|
|
@ -610,7 +610,7 @@ void hlsl::StoreViewIDStateToPSV(const uint32_t *pInputData,
|
||||||
PSVComponentMask(),
|
PSVComponentMask(),
|
||||||
PSV.GetPCInputToOutputTable());
|
PSV.GetPCInputToOutputTable());
|
||||||
}
|
}
|
||||||
DXASSERT(pSrc - pInputData == InputSizeInUInts,
|
DXASSERT((unsigned)(pSrc - pInputData) == InputSizeInUInts,
|
||||||
"otherwise, different amout of data written than expected.");
|
"otherwise, different amout of data written than expected.");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -667,7 +667,7 @@ unsigned hlsl::LoadViewIDStateFromPSV(unsigned *pOutputData,
|
||||||
pOutputData, PCScalars, OutputScalars[0], PSVComponentMask(),
|
pOutputData, PCScalars, OutputScalars[0], PSVComponentMask(),
|
||||||
PSV.GetPCInputToOutputTable());
|
PSV.GetPCInputToOutputTable());
|
||||||
}
|
}
|
||||||
DXASSERT(pOutputData - pStartOutputData == OutputSizeInUInts,
|
DXASSERT((unsigned)(pOutputData - pStartOutputData) == OutputSizeInUInts,
|
||||||
"otherwise, OutputSizeInUInts didn't match size written.");
|
"otherwise, OutputSizeInUInts didn't match size written.");
|
||||||
return pOutputData - pStartOutputData;
|
return pOutputData - pStartOutputData;
|
||||||
}
|
}
|
||||||
|
|
Загрузка…
Ссылка в новой задаче