Alabama lawmakers have passed a bill that would toss doctors in jail for performing an abortion, including for rape and incest, even though the procedure has been legal in America for nearly 50 years.

With an eye on the conservative majority on the Supreme Court, the bill is part of a broader anti-abortion strategy to prompt the U.S. Supreme Court to reconsider the right to abortion.

When Justice Anthony Kennedy was on the court, state lawyers did not seek to challenge Roe vs. Wade, since Kennedy had voted to uphold the right to abortion decades before.

But Brett Kavanaugh, who replaced Kennedy on the court, has been seen as more conservative and open to limiting or overturning the right to abortion.

Republican state Rep. Terri Collins of Decatur, Ala. defended her “Human Life Protection Act” during contentious debate on the House floor.

“This bill is focused on that baby that’s in the womb that is a person,” Collins said. “That baby, I believe, would choose life.”

Democratic lawmakers walked out in protest before the final 74 to 3 vote.

During debate, they questioned the motive for an abortion ban in a state that’s refused to expand Medicaid.

“I do support life, but there are some people that just support birth they don’t support life,” said Democratic Rep. Merika Coleman of Birmingham, Ala. “Because after a child is born there are some things that need to happen. We need to make sure that child has adequate health care,” Coleman said.

Other states, including neighboring Georgia and Mississippi, have passed laws that prohibit abortion once a fetal heartbeat can be detected. But Alabama’s ban would apply even earlier.

“When a woman is pregnant, an abortion is no longer legal,” says Collins, explaining the bill.

The bill criminalizes abortion, meaning doctors would face felony jail time up to 99 years if convicted.

The only exceptions are for a serious health risk to the pregnant woman, or a lethal anomaly of the fetus.

There are no exceptions for cases of rape or incest.

Collins says the bill follows a constitutional amendment approved by Alabama voters last year that recognizes the “rights of unborn children.”

It defies the U.S. Supreme Court’s landmark decision that protects a woman’s right to abortion.

The bill is expected to win final passage in the Republican majority Alabama Senate.

The ACLU of Alabama says it will sue if the abortion ban becomes law.

Executive Director Randall Marshall says the bill is unconstitutional.

“There is simply nothing that Alabama can do to interfere with the right of access to abortion,” Marshall says. “That is a federal right and the Federal Constitution clearly trumps all state law.”

With two Trump appointees now on the U.S. Supreme Court, anti-abortion forces are optimistic that judicial interpretation could be reversed.