Here's the Catholic take:
There are 3 conditions to be culpable for a mortal sin (damned into hell). All 3 must be met
-
it must be serious sin (mortal), so stealing a pack of gum is not; but suicide is.
-
You must know it is a serious sin - if you didn't know, then not culpable
-
Full consent of the will - you chose to do it anyways without coercion.
Both 2 and 3 look pretty darn iffy in this case due to meds, mental illness etc. In fact i think most suicides seem iffy for the very reason it would take almost mental illness to do it.