Montevideo, Uruguay (CNN) -- The senate of the tiny South American nation of Uruguay, the current standard-bearer on progressive policies on the continent, on Wednesday passed a bill legalizing abortion.
Leftist President Jose Mujica has said he will sign the bill into law, which will make it the latest in a number of laws in the region that go against the grain of the traditionally very Catholic, socially conservative Latin America.
With Mujica's signature, Uruguay will become just the second nation in Latin America where abortion is legal.
But the debate over abortion in the country is far from over.
Sen. Jose Amorin, a critic of the bill, said that opponents will begin collecting signatures in an effort to force a referendum where the public could vote down the measure.
The senate approved it in a 17-14 vote.
A similar bill had passed before under a previous congress, but then-President Tabare Vazquez vetoed it.
Under the new measure, abortion during the first trimester of pregnancy becomes decriminalized, and becomes a procedure that clinics can carry out.
A Uruguayan seeking an abortion will first go to a doctor, who in turn will refer her to a panel that includes gynecologists, psychologists and social workers who must explain all of the possible outcomes, the bill states.
There is a five-day waiting period afterward, and if the woman still seeks an abortion, the procedure will be carried out immediately, according to the measure.
Uruguay will join Cuba as the only Latin American countries where abortion is legal outside of cases of rape, incest of danger to the mother's life.
Uruguay has been at the vanguard of the liberalization of social policies that traditionally have been influenced by the Catholic Church. In 2009, the country became the first in Latin America to allow same-sex couples to adopt children.
Uruguay is also proposing a law that would legalize marijuana.
CNN's Rafael Romo and journalist Dario Klein contributed to this report.