GHC 7.8 compatibility, define isLeft/isRight locally, avoiding the Data.Either imports

This is a cherry-pick of c0a37e9bdd524120501511228b1031fc3d97ecd8

Conflicts:
    CHANGES.txt