There are two sides to the squatter law. Obviously it is good that squatters can't take over someone's home without the law turfing them out. But is it so very bad for them to squat in empty derelict buildings?
There is homelessness around for various reasons, but high rents and high prices for houses have to be the main reasons. Other reasons are family breakdown, fleeing abuse, dug abuse, and mental illness. Funding for homeless shelters should be increased so that no-one has to sleep rough unless they choose to do so.
Funding can be a controversial issue, but I don't think comparisons are helpful. Does it really matter whether one group or another is more worthy of finance, for instance? Often there are unknown elements to funding decisions, when funds are taken from one group and funds are given to another. Perhaps one lot is suffering local persecution, but the other has plenty of money to be going on with. Generally speaking, the press keep us in the dark about such things.
One thing is certain though - homelessness is a dreadful thing, and if the government is going to take one solution away, they should replace it with another.