I actually don't know why it wouldn't work. All you're doing is replacing x = a, where a is a function. I can't find a situation where it wouldn't not work, since a = x! It's just saying A = B and then replacing As with Bs really (although of course B can be some random function).
lol
That is the most illogical thing I have ever heard.