FoundationDB/sql-layer — pull request #1383 by ScottDugas (2014-07-31 20:59:26+00:00)
Title: Order by desc

When we have a Union_Ordered, sometimes we need to compare the different values of the union (e.g. if we're sorting over it). This causes the index to preserve that information.

I'm going to refactor the determineOrderEffectiveness method shortly to have less nested if/for/if stuff going on and open a second PR for that.