The 9th Circuit Court of Appeals ruled Tuesday that the Second Amendment protects the right to carry a gun openly in public for self-defense.

A divided three-judge panel ruled in favor of gun owner George Young, who argued his constitutional rights had been violated when his application for a license to carry a handgun publicly was denied.

“Once identified as an individual right focused on self-defense, the right to bear arms must guarantee some right to self-defense in public,” Judge Diarmuid O'Scannlain wrote for the majority. “While the concealed carry of firearms categorically falls outside such protection, we are satisfied that the Second Amendment encompasses a right to carry a firearm openly in public for self-defense.”

With its ruling, the San Francisco-based court, considered to be the country’s most liberal circuit court, reversed an earlier ruling from the U.S. District Court for the District of Hawaii, which sided with the state and county.

Writing for the majority, O’Scannlain said that while “we do not take lightly the problem of gun violence … for better or for worse, the Second Amendment does protect a right to carry a firearm in public for self-defense.”

“While the amendment’s guarantee of a right to ‘keep’ arms effectuates the core purpose of self-defense within the home, the separate right to ‘bear’ arms protects that core purpose outside the home,” he wrote.

The majority said its ruling does not affect a 2016 decision in which the court found the Second Amendment does not protect a person’s right to carry concealed firearms in public.

Judge Richard Clifton dissented from Tuesday's ruling, and wrote that regulations such as those on the books in Hawaii and elsewhere that place limitations on public carry of firearms are “presumptively lawful” and “do not undercut the core of the Second Amendment.”

Clifton predicted the Supreme Court “will find it appropriate at some point to revisit the reach of the Second Amendment and to speak more precisely to the limits on the authority of state and local governments to impose restrictions on carrying guns in public.”

Young filed his lawsuit in June 2012 against the state of Hawaii after applying twice for a license to carry a handgun in public either openly or concealed. The applications, though, were denied by Harry Kubojiri, the county of Hawaii’s chief of police.

According to court filings, the applications were not approved because Young failed to meet the requirements of a Hawaii statute that allows residents to obtain a license to carry a handgun in public “when an applicant shows reason to fear injury to the applicant’s person or property.”