Bob: "... my husband..."
Fred: "oh"
Bob: "What?"
Fred: "nothing"
Bob: "Okay..."
Fred: "....i think i'll go finish my lunch at my desk"
Bob: "hey don't forget to finish that code review for me later"
Fred: <acts different in subtle and plausibly deniable way with Bob from now on"
Bob: "Hey, do you have a problem with me being gay?"
Fred: "DON'T MAKE THIS POLITICAL" etc.
It could, but how would a corporate policy that permits discussing politics help anything? If Fred is anti-gay and going to subtly be a jerk to Bob from now on, do you think that in the alternate reality where discussion of politics were permitted that things would be better? In this alternate reality do you expect Bob to have a quick workplace chat with Fred that convinces him to be cool with gay people?
That's the same argument people use against legalizing gay marriage or creating laws forbidding private businesses from discriminating against gay people. "You're not going to make anyone not homophobic this way!"
No, not immediately. But if you ban politics in this context then you are tacitly encouraging homophobic behaviour.
Bob: "Boss, Fred is being homophobic"
Boss: "What happened?"
Bob: <retells above story>
Boss: "Look, don't ask don't tell. He didn't force you to make it a thing. He didn't say anything. What exactly did he do wrong? He's right, you're the one that made it political, and we banned that at the office."
It's an exit valve out of difficult conversations.
Bob: "... my husband..." Fred: "oh" Bob: "What?" Fred: "nothing" Bob: "Okay..." Fred: "....i think i'll go finish my lunch at my desk" Bob: "hey don't forget to finish that code review for me later" Fred: <acts different in subtle and plausibly deniable way with Bob from now on" Bob: "Hey, do you have a problem with me being gay?" Fred: "DON'T MAKE THIS POLITICAL" etc.