I'm sorry this happened. Here are the immediate responses I would suggest:
- Focus on your finals right now. They are your most important duty to yourself as a student.
- After finals are over, evaluate this in context. (And wait to act until your grade is submitted--nothing you've talked about has connected this to your grade. You could refer back to this SE post if, at some point, someone says you're only bringing this up because you're mad about your grade.) Now that you've had a whole semester, you know the following:
- One other student interpreted the statement that way. (Did others think there was a plausible other meaning, or did it just not occur to them?)
- This was a big enough thing that it made you feel uncomfortable in the class and it is still bothering you now.
- Has the professor done anything else similar since then?
My answer is along the same lines as cag51's, but with more cases.
If this "joke" was part of a larger pattern, then it is very appropriate to address it, possibly with a Title IX Coordinator (if you're in the U.S.) or ombudsperson or other student advocate.
If this was more of a one-off, think about how to address it. A general conflict-resolution principle is to address a problem directly to the person who caused the problem, unless you feel unsafe doing so.
You could shrug it off. If confrontation is going to be painful for you, and/or you judge it is not worthwhile, you could decide not to pursue anything. (If you're asking about this months later, then it seems like this answer is not the right one for you. Further, if the problem were more serious or pervasive, it might be ethically harder to justify this option.)
You could email the professor with your concern, stated factually much like you have above:
[Thank you for your class this semester.] I remain troubled by something that occurred in class early this semester. On [date], you made a joke about rape [in the context of...]. I was too stunned and tired [and sick, if you want to disclose this] to immediately bring this up. Luckily, this did not match the tenor of the rest of your class, but I hope that in future classes you will pick your examples more carefully.
If you want to hit it home, you could also say, "I felt ... when I heard this." or "More than one in every ten U.S. college students experiences 'rape or sexual assault through physical force, violence, or incapacitation' and it is not respectful, especially to survivors of this, to joke about it." But hopefully the professor should understand why you are objecting to a rape joke even without the explicit reasoning.
An email is nice because it is an official record. If the professor ever harrasses someone, even years after you graduate, this record may still be found in the system. If the professor has any sort of reprisal for your bringing this up, the email will also be a helpful record for that.
- At the same time, an email is not generally public. It is there if needed if escalation is necessary, but otherwise this doesn't need to involve anyone else.
If you do not feel comfortable directly approaching the professor, figure out if there is a way to make sure the message is delivered.
- Is the other student willing to email the professor?
- If you discuss the case with someone in charge of the department (e.g. the Director of Undergraduate Studies (DUS) or chair or student advisor), hypothetically/without naming the professor, could they send a message to the faculty reminding them to be considerate of the examples and jokes they bring up?
- When discussing with any third parties, you may want to start asking as a hypothetical or without naming names. You could even explicitly say, "I am not sure that I want this to turn into any official investigation. How can I approach this without you being mandated to report it?"
- All that said, you could also whole-heartedly report it. An isolated incident of this nature will not get anyone fired, though it might force the professor to go though some meetings and paperwork. If you get the sense this professor would not listen to you, this might be the way to go.
- If you or your friend tries an email and that is dismissed, you can then escalate it to reporting to a Title IX coordinator, student advocate, DUS/department chair, dean, etc.
The best case scenario, in my mind, is that the professor said something that they did not fully think through, but they did not intend to make anyone feel unwelcome or trigger anyone's PTSD or anything else. If such a professor got an email that a student was still bothered by it months later, they would actually be grateful you were addressing them directly, realize what a stupid thing it was to do, and assure you that they takes this seriously and will avoid that in the future. I strongly hope that this is, actually, your situation, and that by addressing the matter once, directly, you can make a difference for the professor's future students.