You just need to combine three result from chapter 3 of Rudin's Functional Analysis Book.
Let $(X,\tau)$ be some locally convex topological vector space. Let $(X,\tau)'$ be the space of linear functionals on $X$ that continuous in $\tau$ topology. Since $\tau$ is a locally convex topology, then $X'$ separates points in $X$ (corollary of theorem 3.4).
Let $\tau'$ be topology on $X$ induced by functionals from $X'$, then by theorem 3.10 the space $(X,\tau')$ is a locally convex and surprisingly $(X,\tau')'=(X,\tau)'$.
So, in order to prove the result you mentioned in your question it is enough to consider case when one of the topologies is a weak topology.
Now we apply theorem 3.12. It states, that each convex subset $E$ of locally convex space $X$ have equal closures in original and weak topologies.
And now we are done.