I'm a female Software Developer, working as a provider, sitting in the client's offices, in Germany.
Due to constant misogynistic attitudes(1), sexual harassment(2), and being treated as if I was a hihgly sexualised stupid child(3) I have developed a depression, with phases where I just want to die. I have discussed this with my employer (not the part of feeling suicidal, but mentioning this was making me literally ill) to see if they can give me some other project where I am treated as an adult human being, only to be given the feeling it is all my fault for letting this get to me, and they can't promise it will be different in some other project.
When feeling suicidal I went to the doctor, who put me on sick leave. While this helped a lot, and allowed me to find the strength to search for another job, when I was back I began to feel really bad again (of course).
I am waiting for an potential employer to tell me if they take me or not, but meanwhile I developed some wish to harm myself, so I went to the doctor, and I told him I want to resign due to health problems. His answer to that was that it is a bad idea, that if I am sick for more than 6 weeks I can still get money to live from the health insurance, and he put me on a sick leave.
My question, why it is such a horrific idea to resign without having yet a new job, even if your current job is making you feel suicidal and/or making you want to physically harm yourself or others?
This is related, but doesn't consider the health factor.
Here some concrete examples on why I say my current workplace is so horrible:
(1) Now I am in another office where it doesn't happen that often, but still... Some concrete example: "to be a woman is really an illness", or joking about how fun rape is.
(2) One guy used to stare all the time on my breasts. When I told him to stop, he went angry and didn't even greet me, which I considered an improvement on his attitude. After a while he decided to talk to me again, but continued to stare on my breasts, and began to make comments. When I told my project manager, he wondered why I wouldn't take is as a compliment, and told me how a friend of his thinks it is. While he finally told the harasser to not to comment on any part of my body, he did so while smiling broadly, and telling him I was being very sensible and he didn't thing he was a sexual harasser. He finally asked me if I was wearing normal unisex t-shirts with normal pictures where pictures always are on purpose so that people would stare me on my breasts.
(3) Two days ago, after a comment of mine about leaving for home that day, he told me "I should be put over one's knee" (man muss dich über das Knie legen). It's like the fourth time he tells me exactly that, with the difference that this time I managed to tell him in a very serious voice that this kind of comments make me feel uncomfortable. On the next day he was like "I'm afraid to tell you the wrong thing in case you get angry at me". Some time ago he also had the bad habit to tell me how a friend of him likes to provoke to be stared and commented on his breasts, and how frequent this is on women (it is not).
Edit: I think I misunderstood my doctor and some comments of some freinds and aquitances. It is itself not a terrible idea to quit beacuse of your health, in Germany there are usually better alternatives.