(Fortune) -- Dear Annie: I have a colleague who is also a friend, and I think he's about to make a huge mistake. I'm hoping you (and your readers) can help me talk him out of it. My friend -- call him Ed -- has been working 80-hour weeks to make up for layoffs in our division. In two years, he has not gotten any raises at all, and now his boss has informed him that his bonus for the first quarter will be half what he was expecting. So Ed's going to quit and take a job offer at another company.
Fine, but the thing is, he's writing a long, vitriolic resignation letter spelling out all his complaints. He says he needs to get it all off his chest, and maybe convince higher-ups to treat his replacement more fairly. He's also planning to air his grievances in an exit interview with human resources. I say he's just shooting himself in the foot. Am I right? -- Concerned Coworker
Dear C.C.: In a word, yes. Ed's letter is unwise. "The question is, why are you writing a resignation letter in the first place? There is no legal requirement to do so," says Cynthia Sass, a labor attorney in Tampa who represents individual employees.
For most people, the only reason to resign in writing is that the date on the letter serves to establish the date when notice was given. (Indeed, if it's in e-mail form, the letter will be time-stamped, too.) That matters because some employment contracts and corporate policies dictate that certain perks -- pay for unused vacation time, for instance -- will be granted only if the employee has given a specific amount of notice (usually two weeks, but sometimes longer).
If you're leaving a job because of real or perceived age, sex, race, or religious discrimination, or because you're a whistleblower who is suffering retaliation for speaking up, "you do want to document why you're quitting, because it could make a difference if you decide to sue," says Sass. "But that kind of resignation letter needs to be worded very carefully, so don't try to do it on your own. Get a lawyer to advise you."
It doesn't sound as if that applies to Ed.
"For someone who is simply quitting to take a better job, writing a venomous letter in a fit of anger is a terrible idea," Sass says. No matter how justified Ed's rant, she notes, "telling off your boss won't make any difference to how the company treats your successor -- they'll just write you off as a hothead -- and it could very well destroy your chances of ever getting a good reference from this employer."
A smarter strategy: "Vent to your friends about what is making you angry, but keep your resignation letter brief and factual. Later on, if you really feel you need to express your thoughts on what was wrong with the job, you can write a separate memo outlining suggestions for improving the way the place is run. But do yourself and your replacement a favor and wait until you have cooled off."
Exit interviews are a somewhat different kettle of fish. Cooling off before the meeting is certainly a smart move, but it's ok in that setting to explain some of the reasons why you're taking another offer. After all, unlike in a resignation letter, they're asking you for feedback, and calm, constructive criticism is welcome.
"There is a widespread misconception that you should never be too honest in an exit interview," says Beth Carvin, founder and CEO of Nobscot Corp., which has helped formulate exit-interview policies for T-Mobile, Campbell Soup, General Dynamics, and many other big companies. "But companies do want to hear the truth."
Why? "Turnover is expensive," she explains. "How can they prevent unnecessary turnover if they don't know the real reasons why people are quitting?" Most employers, "aggregate the data from exit interviews and look for recurring themes and patterns," Carvin says. "What are the criticisms that keep recurring? What are the problems that people keep mentioning over and over?"
One of her clients, a major call-center operation with more than 20,000 employees, reads every single exit-interview comment, Carvin says: "As a result, they made some big changes, and cut their turnover by 20%."
Done right, an exit interview is a chance to "get closure on the issues that have been bothering you, and at the same time quite possibly make a real difference in the way people are treated after you're gone."
If you're worried about a harsh comment coming back to hurt your chances of getting a good reference, keep in mind that what's said in HR, stays in HR, Carvin says. Many companies these days even give you the option of having your comments kept on file without your name attached to them.
So Ed's plan to be completely honest in the interview makes sense, she says -- "as long as he doesn't just vent. He needs to prepare for the interview by calmly making a list of constructive suggestions for improvement. If he does that, he's much more likely to be taken seriously than if he just goes in there and blows his stack."
Talkback: Have you ever told off a boss or employer as you were leaving a job, or quit in a huff? Would you be completely honest in an exit interview? Has an employee ever said something critical to you when they resigned? How did you react? Tell us on Facebook below.