Use types have same widths in loop condition. (#4763)
diff --git a/source/val/validation_state.cpp b/source/val/validation_state.cpp
index 0be47b9..6483335 100644
--- a/source/val/validation_state.cpp
+++ b/source/val/validation_state.cpp
@@ -541,7 +541,7 @@
if (inst->id()) all_definitions_.insert(std::make_pair(inst->id(), inst));
// Some validation checks are easier by getting all the consumers
- for (uint16_t i = 0; i < inst->operands().size(); ++i) {
+ for (size_t i = 0; i < inst->operands().size(); ++i) {
const spv_parsed_operand_t& operand = inst->operand(i);
if ((SPV_OPERAND_TYPE_ID == operand.type) ||
(SPV_OPERAND_TYPE_TYPE_ID == operand.type)) {