Probability zero vs impossible I understand that probability $0$ does not mean 'impossible' - because if we look for instance at a uniform distribution over $[0, 1]$ then while each of the singleton events $\{r\}$ for $0\leq r \leq 1$ has probability $0$, if we carried out the experiment then we would get exactly one of the numbers in $[0,1]$, and so these events are not actually impossible, even though they have probability $0$.
However, if we look at a distribution defined by a density function which is zero on $[0,\frac{1}{2}]$ and non-zero on $(\frac{1}{2},1]$ (let's say with a continuous transition between them), then we know that for any $0\leq r\leq \frac{1}{2}$ the event $\{r\}$ is impossible, and for $\frac{1}{2}<r\leq 1$ the event is possible, yet still has probability $0$.
Both have probability $0$, but one of them is possible, and the other is not. Is there a definition that captures this distinction between the two cases?
 A: A real-valued random variable is a measurable function from the sample space to the real numbers. While a continuous random variable can be described by a density function and the density function contains all the information about probabilities of all events, that doesn’t mean that the density function fully defines the random variable. The difference you’re interested is a difference between random variables that doesn’t manifest in their density functions (and hence not in the probabilities of any events).
Consider the sample space $[0,1]^2$ (with the standard Lebesgue measure) and the random variable
$$
X((a,b))=
\begin{cases}
a&b\gt0\;,\\
a+1&b=0\;.
\end{cases}
$$
This random variable takes values on $[0,2]$ and has density $1$ on $[0,1]$ and $0$ on $[1,2]$. Thus it has the same density as a random variable uniformly distributed on $[0,1]$; yet it can take values on $(1,2]$ whereas the latter can’t.
Thus, whether the event of a random variable taking a certain value is possible is determined simply by whether any element of the sample space is mapped to that value; and this need not be reflected in the density (and thus cannot be determined from the density alone).
A: 
However, if we look at a distribution defined by a density function which is zero on $[0,\frac{1}{2}]$ and non-zero on $(\frac{1}{2},1]$ (let's say with a continuous transition between them), then we know that for any $0\leq r\leq \frac{1}{2}$ the event $\{r\}$ is impossible, and for $\frac{1}{2}<r\leq 1$ the event is possible, yet still has probability $0$.

Why do you say that?  Consider the uniform distribution on $[0,1]$.  Let $r$ be any point of $[0,1]$.  Use this density:
$$
f(x) = \begin{cases}
0,\qquad x <0 \text{ or }x=r \text{ or } x>1\\
1,\qquad \text{otherwise.}
\end{cases}
$$
Of course this is still the same distribution: uniform on $[0,1]$.  But now your reasoning says $r$ is impossible.  So your notion of "impossible" depends not on the distribution itself, but in your choice of density function.
A: As mentioned in other answers, one major sticking point is in the mathematical definition of "impossible". 
If you view a random variable as a measurable function
$$
\begin{align*}
X: \Omega &\to [0, 1] \\
\omega &\mapsto X(\omega)
\end{align*}
$$
taking elements $\omega$ of some sample space $\Omega$ (i.e. events) to a real number $X(\omega)$ (the probability of that event happening), one reasonable definition is 
$$
\text{An event } \omega \text{ is } \textbf{possible} \iff \omega \in \Omega
$$
Note that you can still have $X(\omega) = 0$, i.e. $\omega$ occurs with probability zero. Impossible events are then just those events not in the domain of $X$.
