4. Given that $x$ and $y$ are not equal to 0. If
$$
|x+y|=|| x|-| y|| \text {, }
$$

then ( ).
(A) $x>0, y>0$
(B) $x<0, y<0$
(C) $x y<0$
(D) Any case holds
4. C.

From the problem, we have
$$
x+y=-(|x|-|y|)=-|x|+|y|
$$

or $x+y=|x|-|y|$.
Therefore, $x<0, y>0$ or $x>0, y<0$, which means $x$ and $y$ have opposite signs.