Let $x_0\in[a,b]$ be fixed and let $f:[a,b]\to\mathbb R$ be a function with the following property: For every $\varepsilon>0$ there exists some $\delta>0$ and some set $U\subset[x_0-\delta,x_0+\delta]$, where $[x_0-\delta,x_0+\delta]\backslash U$ is of Lebesgue-measure zero, such that $|f(x)-f(x_0)|<\varepsilon$ for all $x\in U\cap[a,b]$.
Can we conclude that $f$ is continuous at $x_0$?
It is clear that $f$ cannot have a jump discontinuity at $x_0$. Is anything known about those functions? Any help or literature recommendation is highly appreciated. Thanks in advance!
EDIT: Thanks to @Mike Earnest for his comment: We cannot say that $f$ is continuous at $x_0$. For example, let $f:[0,1]\to\mathbb R$ be 1 for $x\in\{1,1/2,1/3,1/4,\ldots\}$ and 0 elsewhere. Then $f$ satisfies the property at $x_0=0$, but is clearly discontinuous there.
What about functions that satisfy the property at every $x_0\in[a,b]$? Can they be discontinuous at some point of $[a,b]$?