San Francisco lawmakers upended the rules on the block around the Punch Line Comedy Club in an effort to keep the laughter going at the longtime institution this week.

The 40-plus-year-old Punch Line venue is in danger of closing, as management announced in May that the club was “unable to renew its lease with the current property owners.” The current deal expires in August.

Comedians and politicians alike (natural enemies but united here by a common cause) rallied on the steps of City Hall to save the landmark, with Supervisor Aaron Peskin taking the extra step of proposing “an interim zoning moratorium for 45 days on changes of nighttime entertainment use in the One Maritime Plaza area” to help incentivize a new deal for the longtime tenant.

On Monday, the city’s Land Use and Transportation Committee (chaired by Peskin) speedily approved the measure, which reads, in part:

Protecting existing uses that encourage and enhance street activity at night is imperative [in the neighborhood] particularly on the mezzanine and publicly-accessible upper levels, which were constructed as a part of the plaza build-out of the Alcoa Building in 1967. The existing entertainment uses at One Maritime Plaza regularly activate the upper public mezzanine areas after dark (approximately four hours a week). In addition to enlivening the area at night, Nighttime Entertainment Uses in the area of One Maritime Plaza are an important source of employment for City residents, providing at least 40 service-industry jobs.

The legislation does not mention Punch Line by name, but it’s clear to which business the measure refers.

If approved by the full Board of Supervisors, the moratorium would ward off any other uses for the space besides entertainment, thus presumably making a renewal of Punch Line’s deal the path of lease resistance.

The committee passed the plan 3-0 on Monday with almost no debate. Senior Planner Diego Sanchez noted that the SF Planning Commission had previously given its recommendation in favor of the proposal.

Since opening in 1978, names like Dave Chapelle, Wanda Sykes, Ellen DeGeneres, Marc Maron, and Chris Rock appeared on Punch Line’s stage. The late Robin Williams also used to grace the stage at the noted comedic institution.