The Senate of Argentina voted August 9 to reject a bill that would have erased the country’s constitutional protection for most preborn babies and legalize abortion during the first 14 weeks of pregnancy.

The bill would have also legalized late-term abortions in cases of fetal deformity or to protect mothers’ “psychological” health. The Catholic nation currently allows abortions only for rape or threats to a mother’s life.

The Argentinian Senate gave its preliminary approval to the bill’s finalized text last week. Just days before the final vote, Senator Silvina García Larraburu withdrew her support for the bill, citing her “most intimate convictions.” Thirty-eight senators ultimately voted against the bill and 31 in favor, CNN reports, with two abstentions and one absentee.

The Senate was the final step deciding the fate of Argentina’s abortion laws. The country’s chamber of deputies approved the legislation by a 129-123 vote in June, and Argentinian President Mauricio Macri said he would follow whatever decision the legislature made, despite claiming to be pro-life.

Argentina would have been the third Latin American country to make abortion generally legal, Reuters reports, after Cuba and Uruguay.

Wednesday’s vote followed a contentious public debate both domestically and worldwide, with more than 3 million Argentinians marching to protest repeal and international “human rights” watchdogs such as Amnesty International and the World Bank pressuring Argentina for protecting the rights of preborn humans. Polls showed the public narrowly divided on the question in the run-up to the vote.

The pro-life demonstrators included hundreds of doctors, some of whom waved signs declaring “I’m a doctor, not a murderer” and laid down white medical coats outside of the presidential palace to affirm that abortion is incompatible with their chosen profession. Argentina’s Federation of Gynecology and Obstetrics Societies noted that it wasn’t consulted on the bill, and expressed concern that doctors who refuse to commit abortions would have been penalized.

Yahoo News reported that the bill’s language “provides for conscientious objection for practitioners,” though others remain wary because hospitals as a whole received no such guarantee. Doctors also fear that the requirement that abortion requests be fulfilled within five days could further punish doctors with reservations about particular cases, or even willing providers who can’t find an abortionist that quickly.

Amnesty International took out a back-page ad in the New York Timesfeaturing a coat hanger and claiming complications from illegal abortions are “the leading cause of maternal deaths in Argentina.”

That has been one of repeal supporters’ most repeated talking points, as well as claiming Argentina’s abortion laws fail to prevent half a million abortions a year. Therefore, they argue, banning abortion accomplishes nothing but make abortions happening anyway more dangerous.

Americans United for Life disputed such claims in a 2012 report on the state of abortion in Latin America. Citing statistics from Argentina’s National Ministry of Health, it found that illegal abortions represent a small percentage of maternal deaths.

Ultimately, the vote narrowly averted a major sea change, with Argentina almost following Ireland as another predominantly Catholic nation abandoning the faith’s traditional protection of human life. But despite the relief felt by pro-life advocates today, the closeness of the votes in both chambers suggests the right to life is far from secure.

 A version of this article originally appeared August 9 at LifeSiteNews.com and is used with permission.