Obviously, if $x$ is a Cartesian coordinate, then the corresponding momentum operator is $-i \hbar \partial_x$. But what if $x$ is something more complicated, like some sort of curvilinear coordinate in 3D space?
There is this question elsewhere on this site. Quantum mechanical analogue of conjugate momentum But it's not clear to me that the accepted answer there is really answering the question I am asking. Nothing in the question or answer specifically addresses non-Cartesian coordinates, certainly not in any detail.