A group of Republican senators have re-introduced a religious freedom bill that would shield opponents of same-sex marriage and sex outside of marriage from federal anti-discrimination measures.

The First Amendment Defense Act was resurrected Thursday by Sen. Mike Lee of Utah and 21 Republican co-sponsors after going nowhere in 2015.

The legislation would "ensure" that the federal government could not take discriminatory action against anybody who "speaks, or acts, in accordance with a sincerely held religious belief or moral conviction that marriage is or should be recognized as a union of one man and one woman or two individuals as recognized under Federal law."

It also would prohibit any action against those who believe that sexual relations outside marriage are improper.

When he was running for president in the 2016 race, President Donald Trump said he would sign the measure if it passes both the House and Senate to "protect the deeply held religious beliefs of Catholics and the beliefs of Americans of all faiths," The Hill reports.

Among those co-sponsoring the bill are Sens. Ted Cruz of Texas, Marco Rubio of Florida and Orrin Hatch of Utah.