Changed Vector::compare() to use vector iterator instead of internal elements (fixes #59)