An Australian state has taken a step toward allowing voluntary euthanasia 20 years after the country repealed the world's first mercy killing law.

The Victorian Legislation Assembly passed a euthanasia bill by 47 votes to 37 on Friday after a passionate debate lasting almost 26 hours.

Voluntary euthanasia will become legal in Australia's second most populous state if the bill is passed by the Parliament's upper chamber on Oct. 31.

Australia's sparsely populated Northern Territory in 1995 became the first jurisdiction in the world to legalize doctor-assisted suicide for terminally ill patients.

But the Australian Parliament overturned that law in 1997 after four people had been helped to die. The Australian Parliament does not have the same power to repeal the laws of states such as Victoria.