The gvimrc file that the OP linked to was mine, so I had better own up and admit that it was done for no good reason.
I copied that snippet from Hacking without distractions, which recommends putting it in your vimrc. Then at some point I realized it would be neater to move it into the gvimrc file, but I didn’t think it through clearly and left the if has('gui_running') check in place. You’re right to point out that it is unnecessary, so I have now removed it.
For the sake of posterity, here’s my gvimrc before and after the change.