Don't be a dick about it. Plan ahead, my default for restaurants is ceasar salad and coffee. Maybe fish. Don't make it a topic of conversation and it won't be.
If you need to say anything (you don't) then say "I can't eat X, and it has X in it" not "I don't eat X".
You don't say "I don't eat bleach". You say "I can't eat bleach".
Be a little less self-absorbed and you'll be fine.