A function which changes sign infinitely many times, but for which L'Hôpital's rule works I found a visual proof of the L'Hôpital's rule by Giorgio Goldoni which uses an additional hypothesis: $g'(x)$ (i.e. the function which is at the denominator) cannot change its sign.
My question is this: is this additional hypothesis reductive? Does it exist a function whose first derivative changes sign infinitely many times, but for which the De l'Hospital rule works?

If the denominator changes sign infinitely many times as $x\to a$, then by Darboux' theorem it will be $0$ at points arbitarily close to $a$. That means $\lim_{x\to a} \frac{f'}{g'}$ fails to exist at all, because it can only exist if there is a set $A\ni a$ such that $A$ is open in the domain of $\frac{f}{g}$, and $\frac{f'}{g'}$ is defined everywhere on $A\setminus\{a\}$.
Also, if $g'$ changes sign infinitely often, then so does $g''$ if it exists (and so forth by induction), so no matter what order of L'Hôpital we use, it will fail to work. Thus, higher-order L'Hôpital cannot work for such functions either.
