So I don't buy the premise in the first place. In practice it's an authoritarian, abusive method.
If you have a legitimate reason to disperse people because elements are threatening violence, then disperse them - don't lock the those who are peaceful in with the violent elements.