Maybe it shouldn't be illegal. But as a college student, I can tell you the worst possible thing a professor can do is shout a student down. Its funny how some professors claim that college is supposed to be about "opening the mind" and being "exposed to new ideas" (a premise which I find to be a load of bullcrap) yet some of these very same professors are quite intolerant of anyone who dissents with their views.
I get instate tuition at one of the cheapest public universities in the country (yet is top notch in their STEM degrees), yet it is still over $700 for a 3 credit class. I had a professor last semester who consistently either cut students off, shouted them down, or mocked them if they had any disagreement over what he said. Why the **** am I paying $700 for some snob to get to lecture and test me on their ideology for 3 hours a week, yet if I point out a single flaw in his argument, or point out a single dissenting fact, or offer a single alternative hypothesis I'm automatically wrong because I'm some racist/colorblind-racist/sexist/heartless/biggoted/white supremist who secretly sympathizes with neo-Nazi's and the KKK. Oh and the worst part was half our grade was attendance, so I was pretty much forced to listen to his rants about how science is fiction, gender doesn't exist, drug dealers and murderers are really just poor souls affected by racism, and the media is to blame for gay male couples beating each other. If you are wondering where my inspiration for my signature came from, now you know. It literally was the worst experience in my academic career.
Long story short: Maybe it shouldn't be illegal, but intolerant professors are in infringement on my rights as a student, and have no place in our school system.