[This](https://math.stackexchange.com/questions/2223146/generalizations-of-the-robbins-lemma-and-gaussian-integration-by-parts) is getting no attention, so I'll try this here:

* The Robbins lemma, named after Herbert Robbins, says that if $X\sim\operatorname{Poisson}(\lambda)$ and $g$ is a function for which $\operatorname{E}(|X g(X)|) < \infty,$ then $$\operatorname{E}(Xg(X)) = \lambda \operatorname{E}(g(X+1)).$$
* "Gaussian integration by parts" is an identity that says that under suitable assumptions about the function $g$, if $X\sim N(0,\sigma^2),$ then $$ \operatorname{E}(Xg(X)) = \sigma^2\operatorname{E} (g\,'(X)). $$

Both of these propositions are used in empirical Bayes methods.

Both of these are of the form $$ \operatorname{E}(Xg(X)) = \operatorname{var}(X) \cdot \operatorname{E} ((Tg)(X)) $$
where $T$ is a linear operator on functions $g$.

<s><b>QUESTION:</b> Might there be, for each linear operator $T$, some probability distribution for which this holds? And might all of these be useful in empirical Bayes methods?</s>

<b>(P.S.) BETTER BUT LESS LOGICALLY PRECISE VERSION:</b> Are both of these instances of some more general fact of interest?