In the context of projectively extended real line $\widehat{\mathbb{R}}$, if $f(x)=\frac{1}{\frac{1}{x}}$, then $$f(0)=\frac{1}{\frac{1}{0}}=\frac{1}{\infty}=0.$$
But in the context of $\mathbb{R}$, if $f(x)=\frac{1}{\frac{1}{x}}$, is $f(0)$ undefined or is it zero?
On the one hand, if $g(x)=\frac{1}{x}$ is undefined at $x=0$, then $\frac{1}{g(x)}$ should be undefined as well, therefore in the context of $\mathbb{R}$, $\frac{1}{\frac{1}{x}}$ should be undefined at $x=0$.
On the other hand, if $g(x)=\frac{1}{x}$ and $x=0$, then $g(x)$ can be either $\infty$ or $-\infty$ and that would be the reason why is it undefined, but if we write $\frac{1}{0}=\pm\infty$ instead of saying that it's undefined, can we use
$$\frac{1}{\infty}=\frac{1}{-\infty}=0$$
and then say that, in the context of $\mathbb{R}$, $$\frac{1}{\frac{1}{0}}=0?$$
In the reals $\dfrac 1{\left(\frac 1x\right)}$ is undefined for $x=0$. The limit as $x \to 0$ does exist and is $0$. It is a removable singularity in the function, which just looks like a hole in the graph. You can extend the function to one that is continuous everywhere by defining $f(0)=0$.
The same thing happens for $g(x)=\frac{x^2-1}{x-1}$. This function has a removable singularity at $x=1$, but if you add in the definition $g(1)=2$ it becomes continuous.