Add partition and sift function, and helper sift_rest
Re-implement diverge in terms of ifilterfalse.

Also added ifilterfalse to itertools_compat for compatibility with
python3.