def _non_reducing_slice(slice_):
<EOL>kinds = (ABCSeries, np.ndarray, Index, list, str)<EOL>if isinstance(slice_, kinds):<EOL><INDENT>slice_ = IndexSlice[:, slice_]<EOL><DEDENT>def pred(part):<EOL><INDENT>return ((isinstance(part, slice) or is_list_like(part))<EOL>and not isinstance(part, tuple))<EOL><DEDENT>if not is_list_like(slice_):<EOL><INDENT>if not isinstance(slice_, slice):<EOL><INDENT>slice_ = [[slice_]]<EOL><DEDENT>else:<EOL><INDENT>slice_ = [slice_]  <EOL><DEDENT><DEDENT>else:<EOL><INDENT>slice_ = [part if pred(part) else [part] for part in slice_]<EOL><DEDENT>return tuple(slice_)<EOL>
Ensurse that a slice doesn't reduce to a Series or Scalar.

Any user-paseed `subset` should have this called on it
to make sure we're always working with DataFrames.