The ruling is a result of the country's constitutional court in December last year ruling that the current ban on assisted suicide is a violation of fundamental rights.

Violations of the previous ban have resulted in up to five years in prison.

Under the new legislation - which was approved by all parties except the far right - adults who are terminally ill or suffering from a permanent debilitating condition should be able to get help to end their own lives.

Two doctors, one of whom must be an expert in palliative care, must assess each case.

One of the tasks for them will be to determine if the patient is capable of making a decision independently if he or she wants assisted suicide.

The new law will enter into force in January.

What does it look like in other European countries?

So far, it is only in Switzerland where assisted suicide is legal, in situations where the patient suffers from a fatal disease and has been offered other treatment.

In other countries, such as Belgium, Luxembourg, Italy and Spain, active euthanasia, or euthanasia as it is also called, is legal.

This means that a doctor actively and intentionally, medically contributes or causes a patient's death, at his or her relatives' request.

Both variants are banned in Sweden.