I was always told in my college physics classes to not worry too much about the dirac delta function because it can be made rigorous using distributions or measure theory. I've just started learning some measure theory, and I'm trying to make the connection between the dirac measure $\delta_x$ on $(\mathbb{R},\scr B_{\mathbb{R}})$, and the dirac delta function.
I know that for some fixed $x_0\in\mathbb{R}$, and some measurable function $f$, $\delta_{x_0}f=\int_{\mathbb{R}}\delta_{x_0}\{dx\}f(x)=f(x_0)$, so in the case of the dirac delta function, we just let $x_0=0$, and we get $\int_{-\infty}^{\infty}f(x)\delta(x)dx=f(0)$, and $\int_{-\infty}^{\infty}\delta(x)dx=1$, the latter taken as part of the definition of the dirac delta function.
Here's my confusion: The dirac measure is defined (for $x_0=0$) as $\delta_{0}(A)=\begin{cases} 1, & 0\in A \\ 0, & 0\in A^c \end{cases}$, $A\in\scr B_{\mathbb{R}}$.
$A$ can include a singleton $\{x\}$ since these are also Borel sets, and in this case we have $\delta_{0}(\{x\})=\begin{cases} 1, & x=0 \\ 0, & x\neq 0 \end{cases}$. But the dirac delta function is defined as $\delta(x)=\begin{cases} +\infty, & x=0 \\ 0, & x\neq 0 \end{cases}$. Why is $\delta_0(0)=1$ in the first case and $+\infty$ in the second?