Let $X$ be a metric space. Furthermore, let $E$ be an open subset of $X$. Then, the complement of $E$, or all members of $X$ that are not in $E$, is closed, or contains all of its limit points. I understand this to be true locally around $E$.
However, why is this true when taking into account $X$ entirely. For instance, could there not exist a limit point of $X$ which is not a limit point of $E$? What if there is a point not in $E$ "distant" from $E$ which is a limit point of $X$ but not in $X$? Then, $E$ would still be open, but its complement would not be closed.