Refactoring of comparing version numbers.