Sometimes after I fry something, I wash it immediately in water because it's a bit easier to wash (before the remains stick to the pan).
Does this damage the pan in any way?
If you cool a pan too quickly it could deform, especially if your using a cheap pan. A cast iron pan could crack. This is most likely to happen if you dip a hot pan in cold water.
If you want to get a jump-start on cleaning, de-glaze the pan with a cup of water as you would when making gravy. Pour off this liquid and set the pan aside to cool completely.
This would depend on the kind of pan, the heat level of the pan, and the coldness of the water, if any of these are at real extremes, but I'm guessing that in most cases, you will not have a big problem with pan damage. Make sure there is not a lot of hot fat in the pan when you add the water (which would cause spatters ), but that's more of a personal safety issue than a pan damage issue. There are other things in a kitchen that I'd worry about much more than pan damage (dull knives, for example)
Heated metal will move towards the source of the heat causing the valley in the middle of cheap cook ware. The heated bottom side is hotter than the inner surface of the pan and expands more.
If heated and cooled slow this is much less likely to occur. Cooking at too high a temperature and pouring water in the pan while very hot will cause this type warp.
When I was first married my wife, we had cheap aluminum cookware. She was always warping the bottoms. About once a month I would take the clean skillet and get it quite hot, then holding the pan with a thick oven mit turn it upside down and run very cold water on the bottom of the pan.
I may have to do the trick three or four times but eventually the bottom would be flat as new till she burned something and poured cold water in it again.
Be prepared for a lot of steam: I wore a light jacket when pouring the water on the hot pan to keep the hot steam off my arms (as well as the aforementioned oven mit)
DON'T TRY THIS WITH CAST IRON COOKWARE
Devin_S' answer is a good one but as he said, be cautious if you are using a cheap pan. I use cast iron and carbon steel pans mainly and occasionally very thick bottomed stainless. When I finish cooking (frying or otherwise), as soon as I remove the food I use paper towels to absorb any oil and then add just enough water to coat the bottom of the pan, then only a light scrape is required to loosen any stuck bits. You can then allow the pan to cool and wash it after dinner. I only use soap on my cast iron or carbon steel pans if they are really a mess. Washing with soap 'could' cause food to stick to the pan but I just season with oil, reheat the pan and allow it to cool again before storing it. I've been doing it this way for years using the same pans and my Mother did it this way before me and her Mother before her. Never had a pan warp or crack.