REF: use np.where instead of maybe_upcast_putmask in nanops
This way we make at most one copy.  Also we get rid of the only use of maybe_upcast_putmask that has fill_value of anything other than np.nan, so in a follow-up it can be simplified.