Fixed signed/unsigned types comparison
BUG=18368388
Change-Id: I3f2927fd68e75a8fb5abde1b25e81416862076fc
Reviewed-on: https://swiftshader-review.googlesource.com/1474
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <nicolascapens@google.com>
diff --git a/src/Shader/VertexProgram.cpp b/src/Shader/VertexProgram.cpp
index a07fbb5..a12083f 100644
--- a/src/Shader/VertexProgram.cpp
+++ b/src/Shader/VertexProgram.cpp
@@ -76,7 +76,7 @@
}
// Create all call site return blocks up front
- for(int i = 0; i < shader->getLength(); i++)
+ for(size_t i = 0; i < shader->getLength(); i++)
{
const Shader::Instruction *instruction = shader->getInstruction(i);
Shader::Opcode opcode = instruction->opcode;
@@ -90,7 +90,7 @@
}
}
- for(int i = 0; i < shader->getLength(); i++)
+ for(size_t i = 0; i < shader->getLength(); i++)
{
const Shader::Instruction *instruction = shader->getInstruction(i);
Shader::Opcode opcode = instruction->opcode;
@@ -726,7 +726,7 @@
if(localShaderConstants) // Constant may be known at compile time
{
- for(int j = 0; j < shader->getLength(); j++)
+ for(size_t j = 0; j < shader->getLength(); j++)
{
const Shader::Instruction &instruction = *shader->getInstruction(j);