AUSTIN, Texas — Texas’ new law allowing concealed handguns in college classrooms, buildings and dorms has barely started and already faces a legal challenge seeking to block it before students return for the fall semester.

Three professors at the University of Texas sued July 6 to overturn the law, claiming it is unconstitutional and is forcing colleges to impose “dangerously-experimental gun policies.” The 50,000-student Austin campus has been a flashpoint of opposition to the law among faculty and students.

The law took effect Monday, the 50th anniversary Charles Whitman’s sniper attack from the top of University of Texas campus clock tower, a shooting spree that eventually claimed 17 lives and has come to be accepted as the nation’s first mass shooting.

U.S. District Judge Lee Yeakel had previously scheduled a preliminary injunction hearing for Thursday in Austin. Classes at the University of Texas start Aug. 24.

Texas has allowed licensed concealed handguns in public since 1995 but had previously made college buildings off limits.

The new law makes Texas one of eight states with laws that allow weapons on campus and inside buildings, according to the National Conference of State Legislatures. Another 23 let their campuses or governing boards decide.

Texas Attorney General Ken Paxton on Tuesday called the lawsuit “frivolous” and urged its dismissal. Gun rights advocates say it’s a key self-defense measure that is protected under the Second Amendment right to bear arms.

“I’m confident it will be dismissed because the Legislature passed a constitutionally sound law,” Paxton said.

The Texas law allows schools to set some gun limits, such as banning weapons from campus hospitals or labs with dangerous chemicals. The University of Texas rules allow professors to ban weapons from their private offices and places some restrictions on dorms.

The lawsuit by sociology professor Jennifer Lynn Glass, creative writing professor Lisa Moore and English professor Mia Carter says allowing guns into classrooms could be dangerous when discussions can wade into emotionally and politically charged topics such as gay rights and abortion.

“Compelling professors at a public university to allow, without any limitation or restriction, students to carry concealed guns in their classrooms chills their First Amendment rights to academic freedom,” their lawsuit says.

The lawsuit also challenges claims that the law is protected by the Second Amendment right bear arms and says it violates the Constitutional equal protection clause.

Texas’ Republican-majority Legislature passed the law in 2015 over similar objections from student and faculty groups, most notably at the Austin campus.

University of Texas System Chancellor, former Retired Adm. William McRaven, a former Navy SEAL who coordinated the raid that killed Osama bin Laden, urged lawmakers not to pass the law, telling them allowing guns would make campuses “less safe.”

University of Texas administrators and faculty have warned the law will make it difficult to attract and retain top students, teachers and researchers. University of Texas School of Architecture dean Fritz Steiner cited the law as a reason to leave the school for a job at the University of Pennsylvania.

But those worries haven’t resonated statewide. At Texas A&M University, Chancellor John Sharp supported the law and professors there won’t be allowed to ban weapons from their offices without special permission from the administration.

Supporters of the campus carry law say its impact is overstated, because most students won’t be legally allowed to carry concealed weapons.

Texas law requires handgun license holders to be 21 years old (18 if active military), have clean criminal records and pass classroom and gun range training, although training requirements have been reduced in recent years. Texas recently passed 1 million handgun license holders.

The law does not allow open carry of handguns in college buildings and all weapons must remain out of sight.