(CNN) Republican Sen. Jeff Flake announced Wednesday he's backing a bill to increase the minimum age to buy a semi-automatic rifle, lending bipartisan support to legislation that was introduced last week by Democratic Sen. Dianne Feinstein in the wake of the mass shooting at a high school in Parkland, Florida.

"A kid too young buy a handgun should be too young to buy an #AR15," Flake, of Arizona, said in a tweet . "Working with @SenFeinstein on a bipartisan bill that will raise the minimum purchase age for non-military buyers from 18 to 21 - the same age you currently have to be to purchase a handgun."

A kid too young buy a handgun should be too young to buy an #AR15. Working with @SenFeinstein on a bipartisan bill that will raise the minimum purchase age for non-military buyers from 18 to 21 - the same age you currently have to be to purchase a handgun. — Jeff Flake (@JeffFlake) February 21, 2018

The idea has emerged as potential compromise among GOP and Democratic lawmakers -- who are sharply divided and therefore gridlocked on gun control issues -- as they search for a response to killings by 19-year-old Nikolas Cruz, a former student at the school. Cruz used an AR-15 style weapon, which he purchased legally, to kill 17 people.

They are also considering a bipartisan bill to improve reporting compliance by states and federal agencies to the National Instant Criminal Background Check System.

"Under current law, licensed gun dealers cannot sell a handgun to anyone under 21, but they are allowed to sell assault rifles like the AR-15 to anyone over 18. This policy is dangerous and makes absolutely not sense," Feinstein of California said when introducing her bill last week. "If you can't buy a handgun or a bottle of beer, you shouldn't be able to buy an AR-15."

Read More