MISHNAH. ONE MAY NOT CLOSE [THE EYES OF] A CORPSE ON THE SABBATH, NOR ON WEEKDAYS WHEN HE IS ABOUT TO DIE, AND HE WHO CLOSES THE EYES [OF A DYING PERSON] AT THE POINT OF DEATH IS A MURDERER.
GEMARA. Our Rabbis taught: He who closes [the eyes of a dying man] at the point of death is a murderer. This may be compared to a lamp that is going out: If a man places his finger upon it, it is immediately extinguished
This is one of the classic texts relating to Physician Assisted Suicide and other questions about hastening death. It is countered with texts which disallow slowing down the natural process. One may (perhaps must) keep a patient comfortable, even if the side-effect is fatal. But one cannot intentionally hasten death.
And, unrelated but had to share -
It was taught, R. Eleazar ha-Kappar said: Let one always pray to be spared this fate [poverty], for if he does not descend [to poverty] his son will, and if not his son, his grandson, for it is said, because that for [bi-gelal] this thing, [etc.]. (Deut. 15:10)
The School of R. Ishmael taught: It is a wheel [galal] that revolves in the world
It was taught R. Gamaliel Beribbi said: And he shall give thee mercy, and have compassion upon thee, and multiply thee: (Deut. 13:17) he who is merciful to others, mercy is shown to him by Heaven, while he who is not merciful to others, mercy is not shown to him by Heaven."