I had case where I wanted to substitute _F=(y-x^2)/x in an expression obtained which is
x*diff(F1, x) + 2*y*diff(F1, y)
Using eval does not work
Also using delayed does not work
Also using subs does not work
However, delayed with subs finally worked
restart; subs(F1=(y-x^2)/x,'x*diff(F1, x) + 2*y*diff(F1, y)'); value(%) x*(-2 - (-x^2 + y)/x^2) + 2*y/x
So the rule is, if you want to replace a function inside diff, use subs and not eval, and make
sure to delay evaluation of the expression and then use value() to obtain the final
result.