Right so there would be no professional opinion against homosexuality sort of like Al gore imagines with global warming
That’s different. He’s a politician. His job is to give opinions.
Suppose you are against abortion. You can voice that opinion as much as any other citizen, but if you sign your petitions as Doctor John Smith, of Saviors Hospital, then you are using your association as a Doctor and (more importantly) as part of the staff of the hospital to reinforce the validity of your stance. Your professional status isn’t a gag, but neither is it a loudspeaker.