If you're not quite sure what I'm getting at then you should examine the practice of institutionalization that used to occur in the United States and all the many great reasons we have not continued with it. Or the many famous examples of writers attempting to become involuntarily committed so they can detail just how difficult it is to get out and prove to these often unaccountable organizations that you are not, in fact, "severely mentally ill."
I wonder about the jurisprudence of other nations that use these practices in ways which a US citizen might find decidedly uncomfortable, as was pointed out by the OP, particularly when it comes to the nature of involuntary patient /treatment/ and not just simple social separations for the good of the community.