Let's say that you thank Professor X in your paper that you will submit to a Journal Y for providing you some insightful comments. It is never possible to know but let's assume that Professor X is the anonymous referee for your paper. This is possible since you make a list of potential referees (this is quite common for some journals).
What would be the reaction of an editor?