I just upgraded from my 40D to 50D so I think as both user you would like to hear my take on this.
After using 40D for a short while, somehow I find that many shots I took didn't focus so well. I thought it was the camera and lens problem , so i sent it to canon immediately after I bought. They said they calibrated it but some how the shoots are never what I expected from a Canon 40D. (I must admit I was using the Kit lens).
Now that I am using the 50D, WOW! Blind me brother! I feel like a pro. Every shot is like what I expected in a Semi Pro DSLR. very Sharp. I spoke to one other 40D user and he experienced the same thing.
But Mainly, the 50D LCD is like 3 times clearer.. that really is a huge difference to me, cause it is so morale boosting to see great shots on the screen.
If you can afford it.. 50D hands down.