assigning a value to x in diff(f(x),x)



Dear all,

I have written a function separable(expr,x,y) that returns [f(x),g(y)] if expr is separable, and false otherwise.
However, I have a problem with the exotic case where expr contains the derivative of an unknown function f(x), i.e. when expr:diff(f(x),x)*y
The problem is that the algorithm works by assigning a value to x.

Is there a way to make 'something like this' work:

depends(f,x);
define(F(x),diff(f,x));
F(0);

which should then result in the equivalent of  f '(0).