This function returns a generator object that yields sorted items from
'iterable'.
It implements a form of lazy sorting that's most useful in two cases:
1) When you only need the first few values in the sorted data.
2) When you want to amortize the cost of the sort over the time
you use the data.
It is to be considered a 'stable sort', where values with equivalent
sorting criteria maintain their relative order as it is in the input
data set.
'cmp' MUST return values in [-1,0,1]. Otherwise, behavior is
undefined, and will most likely be very incorrect.