The following is Proposition $2.1(c)$ of Folland's A Course in Abstract Harmonic Analysis.
Let $G$ be a topological group. If $H$ is a subgroup of $G$, then so is $\overline{H}$.
The proof uses net convergence. If $x,y\in \overline H$, there are nets $\{x_\alpha\}$ and $\{y_\alpha\}$ converging to $x$ and $y$ respectively. The net $\{(x_\alpha,y_\alpha)\}$ converges to $(x,y)$ in $G \times G$, and so, by the continuity of the map $(a,b) \mapsto ab$, the net $\{x_\alpha y_\alpha^{-1}\}$ converges to $xy^{-1}$. Therefore, $xy^{-1} \in \overline H$, and $\overline H$ is a subgroup of $G$.
Question: I wish to know if the converse is true, i.e., if $H$ is a subset of $G$, and $\overline{H}$ is a subgroup of $G$, is $H$ necessarily a subgroup of $G$? In general, I suspect this to be false, though concrete counterexamples would help. For which class of topological groups is the converse true?