Fixed compare errors.

When values are equal operators: 'operator<', 'operator>', 'operator>=' and
'operator<=' produce incorrect result. Add test test_compare.cpp.
Merge pull request #3 from ruslo/compare.errors

Fixed compare errors.