Silence sign comparison warnings.

Iterate with size_t instead of int when going from 0..container.size().
Also fixed some unused parameter warnings since it wouldn't compile cleanly otherwise.