If $f:X \to Y$ is a continuous function such that $f|_A =y$ then is $f|_{\bar{A}}=y$? If $f:X \to Y$ is a continuous function such that $f|_A =y$ then is $f|_{\bar{A}}=y$? Here $A \subset X$ and $\bar{A}$ is the closure of $A$.
This statement came across my head as I was looking at the below example.
Let $\chi_n \in C^{1,2}([0,\infty) \times \mathbb{R}^d)$ with compact support, $\chi_n |_{[0,1/2n]\times \mathbb{R}^d}=0$ and $\chi_n |_{[1/n,t]\times B(0,n)}=1$.
For the use of this cut off function, I need $\chi_n$ to be $1$ also on $[1/n,t]\times \bar{B}(0,n)$. And I think this is true by using a sequential argument, i.e., any point on the boundary of $[1/n,t]\times B(0,n)$ is a limit of a sequence of points in $[1/n,t]\times B(0,n)$, and so by continuity we get $1$ on the boundary as well. 
So I was wondering if this result holds in the more general case above. I know it holds for $T_1$ spaces, but I am curious if there's any space that such a result would not hold.

If $Y$ is separated, then $\{y\}\subset Y$ is closed. The inverse image of a closed set is closed, so $B=f^{-1}(\{1\})$ is closed, since $A\subset B, \bar A\subset \bar B=B$.
Otherwise, take $\mathbb{R}$ with the topology for which the open subsets are the empty subset and $\mathbb{R}$, every map $\mathbb{R}\rightarrow \mathbb{R}$ is continuous. The adherence of a non empty subset is $\mathbb{R}$, take $f$ to be the identity map $A=\{1\}, \bar A=\mathbb{R}, f_{\mid \{1\}}=1\neq f_{\mid\mathbb{R}}$.
