[tex]\dfrac{\partial f}{\partial x}=\cos x\sin y\implies f(x,y)=\sin x\sin y+g(y)[/tex]
[tex]\dfrac{\partial f}{\partial y}=\sin x\cos y=\sin x\cos y+\dfrac{\mathrm dg}{\mathrm dy}[/tex]
[tex]\implies\dfrac{\mathrm dg}{\mathrm dy}=0\implies g(y)=C[/tex]
[tex]f(x,y)=\sin x\sin y+C[/tex]
[tex]\displaystyle\int_{\mathcal C}\cos x\sin y\,\mathrm dx+\sin x\cos y\,\mathrm dy=\int_{\mathcal C}\mathbf f\cdot\mathrm d\mathbf r=f\left(\frac{3\pi}2,\frac\pi2\right)-f(0,-\pi)=-1[/tex]