THE NATION that welcomed Mikhail Gorbachev last week is about to open its doors a little wider for other controversial visitors. A conference committee considering the Foreign Relations Authorization Act has agreed to accept an amendment passed by the Senate unanimously that will clear up an area of the law that had become embarrassingly murky. As soon as the authorization bill is accepted by both houses -- probably early next week -- this language will be law: "Notwithstanding any other provision of law, no alien may be denied a visa or excluded from admission into the United States, subject to restrictions or conditions on entry into the United States, or subject to deportation because of any past, current or expected beliefs which, if engaged in by a United States citizen in the United States, would be protected under the Constitution of the United States." There are a couple of enumerated exceptions, but basically that's it. Clear as a bell.

The clarification is necessary because for decades there has been litigation, debate, confusion and various shifting forms of paranoia over the question of which foreigners with unpopular beliefs and views should be allowed to visit this country. Right now the State Department claims the authority to exclude foreigners based on their affiliations and beliefs, and this has been interpreted to allow visa denials on the grounds of anticipated speech in this country. Poets, writers, journalists, NATO generals, political figures and assorted critics of the United States have been kept out not because anyone is afraid of what they will do here, but of what they might say. It's nonsense, and it gives the impression that this is a frightened country worried about citizens falling under the spell of some propagandist and turning to revolution.

Two hundred years ago the men who wrote the Bill of Rights took a chance on the intelligence and good judgment of their fellow citizens. They gambled that if Americans were free to hear every viewpoint, challenge any theory and debate the merits of any controversial idea, they would choose the right course. It is this freedom of speech, so cherished by citizens and protected by courts, that should not be penalized when invoked by foreigners. Thanks to Sens. Moynihan, Simon and Kassebaum, who sponsored the Senate amendment, and to Rep. Barney Frank, who has led this effort for years in the House, the law on visas will now reflect this high ideal.