BUG: fix shuffling of flexible dtypes and masked arrays

closes gh-4270 and gh-3263
also regenerate with cython 0.20.1