Fix dimension dropping in slicing.