Suppose that $f g$ is in $L^1([a,b])$ for every $f$ in $L^2([a,b])$, I understand that this implies that $g$ is in $L^2([a,b])$. Is this assertion true and, if so, how do I prove it?
This question was set as an exercise in the book An Introduction to Lebesgue Integration and Fourier Series by H. Wilcox and D. Myers. It should actually be an "easy" exercise as no hint is provided and its proof should not require more than basic concepts on the $L^2$ function space.
I would expect that the proof starts by assuming that $g$ is not in $L^2$ and then continues by showing that, for a suitable choice of $f$ in $L^2([a,b])$, the product $f g$ is not in $L^1([a,b])$. But I am unable to arrive at a complete proof.
I have seen a more general version of this question in this post but its focus is slightly different and the explanation provided there relies on the notion of -finite measure spaces with which I am not familiar. I would therefore be grateful if someone could re-cast the reasoning in that post to more closely match the specific case raised in my question (or perhaps provide a simpler proof, if it exists).