The first part of this answer focuses on the fundamental idea of miscommunication in general. The second part focuses specifically on sarcasm in answers. Take them independently.
TL;DR:
- This issue is too big and fundamental to solve, and is not SO-specific.
- I don't think it's appropriate for a community-wide policy.
- I do think it's reasonable for you to leave a comment if you want to. I think it's equally reasonable not to.
- Things like turning this into a teaching moment, etc. These are great strategies case-by-case (and by "case" I mean per-answer, not per-writer), but in the bigger picture of course we cannot solve this problem.
- If you do want to address a sarcastic post, I've found that there are a couple other strategies that are more effective than a direct confrontation.
Here is what communication (through text) essentially is as I see it (we're all programmers here, so here's a diagram):
Ideal communication is when the writer successfully encodes their idea to written form such that the exact same idea is ultimately placed in the reader's head. Language is nothing more than a fuzzy protocol for idea transmission. When the reader reconstructs a significantly different idea than the writer intended we often call this "not being on the same page".
Of course, to be clear, this is only my personal view of communication. There are many other good and reasonable ways to look at it, but this view is what I am basing this post on.
The art of being a good writer lies in having the ability to encode your idea to written text in a way that maximizes the number of people who are able to accurately reconstruct your idea in their head upon reading your text, given that people, especially from different cultures or who speak other languages, can have massively different ways of processing information that any one person could never expect to truly understand / accurately predict. It can be tricky, and I think failures here sometimes deserve some forgiveness.
Now, the point of this is this: Fundamentally, you're looking for a partial (limited to sarcasm) general solution to miscommunication. In the case of sarcasm in answers, at least the way you've framed it, it is a combination of significantly different worldviews on the part of the writer and reader combined with language barrier issues.
The "problem" (which I quote not out of disrespect, but because it's a matter of choice to view this as a problem vs. a simple "fact of life") you are looking to solve is too big and too intrinsic to human communication to be solved by a specific directed comment here and there. We cannot solve this, at least not in the general sense.
It's totally reasonable and within your rights to leave comments pointing out miscommunication, and if you want to do so, you should, but I do not think it is a good or effective idea to make a general community-wide policy out of this. In a big picture sense, I believe this will have the following results in order of decreasing likelihood:
- You end up causing a non-constructive confrontation. You're essentially criticizing a person's fundamental communication style, in many cases what you're criticizing is way too ingrained in a person's thought process for them to even see it.
- Your comment is well-received and the person improves their text, but likely reverts back to their natural style in the future.
- The person has some sort of epiphany, and changes their fundamental writing style forever.
- Many people reading your comment have that epiphany, and community members change their fundamental writing styles en masse forever. This is your ideal result, and is also very unlikely.
At the end of the day, what I believe you will have is a combination of confrontational comments and perhaps one or two successes, but all in all no change. You cannot unify the global community's ability to encode and decode ideas into language. We're all different and this is an uphill battle.
So leave the comment if you want, but I don't like the idea of this becoming some sort of meta-citable policy.
As for sarcasm specifically, here are some things you can do. Please note that I come at this from the POV of somebody who is very sarcastic in real life and text (and, re the above, trust me, I try to work on this, but it is simply in my nature and no amount of comments to me could make me do this naturally). So much so, in fact, that IIRC an AIM conversation in college where my sarcasm was not understood ultimately led to my college girlfriend breaking up with me, and I just thought the whole thing was funny. So, that's my mindset, heh.
Anyways, if you choose to leave a comment, which I do think has merit on a case-by-case basis, the way I see it there are two particularly effective options:
Simply edit / suggest an edit to the post, with an appropriate edit summary such as "Removed sarcasm". To smooth this over, you may prefer to add a rationale and optional modest patronizing in the summary, such as "Clarified post. While this joke was funny, non-English readers could easily misunderstand.".
I find this option to be weird but consistently effective: If you identify sarcasm, pretend there is no sarcasm, then ask for clarification in a comment. That's it. While this is fairly passive, I've found it to be an effective solution that has a low chance of leading to confrontation.
For #2, as an example: If somebody says "Sure, just use jQuery" (weak example but whatever; also, pretend in context that jQuery is not an appropriate solution), rather than telling the person not to be sarcastic, pretend they aren't, then ask "I took a look through the jQuery documentation right now and I'm actually having trouble finding something that does X. Do you have an example or can you point me in the right direction?" In other words, you're sort of taking one for the team and pre-emptively assuming the role of a confused reader before anybody becomes truly confused.
Usually, in my experience, rather than being met with confrontation or irritation, this ends up being met with "Sorry, I was being sarcastic, what I actually meant was...", or an edit. Mostly this is because you've indirectly given the person the power to come to the realization that their post was confusing on their own, which, in general, is a major key to being effectively constructive.
There are other strategies you may be able to think of, too, for example Bart's ideas are another good approach to consider.
Anyways, that's the end of this long post.