Yes
The relevant Swiss law is known as the FATCA Agreement and has been in force since 30/6/2014. FATCA stands for the Foreign Account Tax Compliance Act, a unilateral set of US regulations that applies worldwide for all countries. It requires foreign financial institutions to disclose information on US accounts to the Internal Revenue Service or levy a high tax.
At the moment, Switzerland uses the "Model 2" agreement with the USA, which requires the consent of the US taxpayer or an administrative request by the IRS. There are plans to move to the "Model 1" arrangement, which uses automatic data sharing, but the timeline is uncertain.
The bank is required to verify that your friend is not a US tax resident, and the visa is one of the pieces of evidence they need. Your friend can, of course, refuse to produce it. The bank can then either refuse to do business with them, or treat them as though they are a US tax resident and withhold the required tax until such time as they prove they are not.