Moved ismethod into compat module.

And changed try/except to branched logic on Python version. This is intended to
address issue #44 and thus the feedback on PR #43.