Fix compare methods and use type_code in __cmp__
Basic.__cmp__ comments
Merge pull request #352 from isuruf/compare

Fix compare methods and use type_code in __cmp__