Is closure of a semigroup again a semigroup? Let $S$ be a compact left-topological semi-group (meaning, $S$ is both a semi-group and a compact Hausdorff topological space, and the map $x \mapsto x y$ is continuous for any fixed $y$, but the map $y \mapsto xy$ may not be continuous).
Consider $T_0 \subset S$ which is a sub-semigroup, but is not necessarily compact. A rather straightforward application of Kuratowski-Zorn shows that there exists a minimal compact sub-semigroup $T$ of $S$ which contains $T_0$. Wishful thinking suggests that $T = \overline{T}_0$, and this would be right and easy to show, if only multiplication was continuous in both arguments. It would also work under the assumption that $T_0$ is commutative.
I do not believe this is true in general, but I can't see an easy counterexample. Could somebody be so kind as to present one? Of course, if it is generally true that $T = \overline{T}_0$, then I would be even happier and more grateful!
 A: Promoting the comments to an answer:


*

*tomasz points out that we have $$T = \bigcap \{G \mid G \supseteq T_0 \text{ is a closed subsemigroup of }S\} \supseteq \overline{T}_0.$$

*The semigroup $S = \operatorname{Fun}(X,X)$ of all functions $f \colon X \to X$ on a topological space $X$ is a left-topological semigroup under composition when equipped with the topology of pointwise convergence, i.e., the product topology $X^X$. Observe that $g \mapsto fg$ is continuous if and only if $f$ is continuous, so on a non-discrete $T_1$ space $S$ is not a right topological semigroup.

*Martin Sleziak remarks that Arhangel'skii-Tkachenko provide the following counterexample in Topological groups and related structures (example 1.4.11).
Consider the one-point compactification $X = \mathbb{N} \cup \{\infty\}$ of the natural numbers. Then $S = \operatorname{Fun}(X,X)$ is a compact left-topological semigroup. 
Let $T_0 \subset S$ be the subsemigroup consisting of injective functions $X \to X$. The functions $f_k$ defined by $f_k(n) = n+k$ for $n \in \mathbb{N}$ and $f_k(\infty) = \infty$ are in $T_0$ and they converge pointwise to the constant function $f(n) = \infty$, so $f \in \overline{T}_0$.
Let $g(n) = n+1$ and $g(\infty) = 1$, so $g \in T_0$. We have $g \circ f_k \in T_0$ and $g \circ f(x) = 1$ for all $x \in X$. Since $g \in T_0 \subseteq T$ and $f \in \overline{T}_0 \subseteq T$ we have that $g \circ f \in T$. Now observe that $g \circ f \notin \overline{T}_0$. Indeed, the set $U = \{s \in S \mid s(1) = 1\text{ and } s(123) = 1\}$ is open in $S$ and disjoint from $T_0$, while $g \circ f \in U$, so $g \circ f \in T \setminus \overline{T}_0$.
