Let $W^{k,p} (\Omega)$ be a Sobolev space, $\Omega \subset \mathbb{R}^N$. Formally, $W^{k,p}(\Omega)$ consists of equivalence classes of functions with finite Sobolev norm. Two functions, $f$ and $g$, are said to be equivalent ('equal') if $\Vert f-g \Vert_{W^{k,p}} =0$.
In many proofs concerning Sobolev functions, say, Poincaré inequality, one first shows the claim for smooth functions and then generalises by using the fact that smooth functions $C_0^{\infty} (\Omega)$ are dense in $W_0^{1,2}(\Omega)$.
However, it is unclear to me what is meant by writing $u \in C_0^{\infty}(\Omega)$. Does it mean that $u$ is equivalent to a smooth function (in the $W^{1,2}$ sense) or that $u$ is itself a smooth function? One proof for Poincaré inequality on $\Omega:=(a, b)\subset \mathbb{R}$ starts by writing the value of $u \in C_0^{\infty}(a, b)$ as $$ u(x)=\int_a^x u dx+u(a), $$ however, if $u$ is considered to be a Sobolev function, one cannot talk about its point wise values, $u(a)$ in particular. Or is it some kind of an agreement that $u(a)$ is the value of the smooth function to which $u$ is equivalent (in $W^{1,2}$)?
Another confusion arises when talking about the trace operator. In the Wiki page, it is said that the trace $T: W^{1,p}(\Omega) \rightarrow L^p (\partial \Omega)$ is such that $Tu = u\mid_{\partial \Omega}$ for any $u \in W^{1,p}(\Omega) \cap C(\overline{\Omega})$. Again, $W^{1,p}$ consist of equivalence classes whereas $C(\overline{\Omega})$ consists of functions. So does the intersection mean functions with finite Sobolev norm which are equivalent to some continuous function? And is $u\mid_{\partial \Omega}$ the boundary function of $u$, or the set of functions equivalent to it?