Remove negative check of unsigned int

I remember seeing that there was a reason that `index` was kept as an unsigned int, but since it is Clang complains about comparing it with a negative value.