Have you ever been reading a fantasy story set in another world, or in a pre-historical version of this one and been stopped by a modern profanity? You stop and think “I get the point, but didn’t that expression only become an exclamation in the past xxx years?”
If you haven’t, that’s probably because you aren’t me and don’t have my odd quirks. Nevertheless, it’s still anachronistic.
Let’s take a popular one: “Damn!” Most of us know that this word means to cursed to hell, to be condemned, or to suffer eternal punishment.
At first, it doesn’t seem to be anachronistic. People, no matter their faith, have pretty much always believed in eternal reward or punishment, and it’s a powerful thing, so why not curse with it?
The thing is, I believe the phrase originally simply meant “to judge.” Also, it did not appear until the 13th or 14th century, which was after the invention of firearms. Most High Fantasy stories are not aiming to emulate that time period. Generally, we usually have worlds that exist between 300 BC to 1000 AD.
My point is this: High Fantasy or old world authors, invent your own curses! Whether you can explain them away or not, modern curses just don’t feel right in a wrong setting, just as words like “Dude” are unlikely to work. It has far more ring if you invent something relevant to your world. For example, in Brandon Sanderson’s The Way Of Kings, the characters often exclaim “Stormfather!” If you have read the story, you probably know that it works. It fits the world. And it sounds a whole lot better than an armored Knight exclaiming “Crap!” At least, that’s my take on it.