When using a union as a restriction, bind free variables  from left to right whiel discarding matching types
Added Enumerable#compact_map (thanks @kostya for the idea) and fixed return type of Array#compact