The domain of the function is all real numbers, but it behaves unexpectedly for negative inputs. Specifically, the function returns -2 for any negative input.

