Add support for PHP7 "spaceship" operator
Summary: Add support for the new PHP7 "spaceship" operator. The invokation "A
<=> B" compares A and B and returns -1 if A is less than B, 0 if they are
equal, and 1 if A is greater than B.
Supporting this involves adding a new bytecode instruction called "Cmp", as well
as a handful of new IR opcodes for each type. This utilizes most of the
machinery of the IR type-specific opcode conversion. Note that this operator
cannot be simply be de-sugared into a set of less-than and greater-than
operations, because that would be observable for types that invoke user code
during comparisons.
Closes https://github.com/facebook/hhvm/issues/5499
Reviewed By: @swtaarrs
Differential Revision:
D2438952