Hey, in the Soviet Union, there was a criminal charge for attempted suicide. If you didn’t succeed in killing yourself, you’d end up in prison (sometimes in a mental hospital, but only sometimes).
That’s why it was worth seeing suicide through to the end.
In modern society, not everyone is punished for suicide. For example, in Switzerland, euthanasia (death by injection) is officially permitted, but it’s not that easy to obtain. Thus, there are places where suicide is a permissible choice without condemnation or punishment.
I think punishment for suicide depends on the level of development of a particular population. In more developed societies, it doesn’t exist at all, as in Switzerland, for example.