Empathy isn’t a feeling that happens to you, it’s a skill you practice.
Everyone knows about common human emotions. What you don’t know about a stranger is when they have those emotions and when they don’t. What most people think they’re doing when they say they’re being empathetic is engaging in projection. They’re imagining themselves in that situation and assuming the other person is feeling the same way they are.
Do I even have to tell you how often that’s wrong? Many, many people think another person is angry when they are angry and they project their anger onto the other person. It totally baffles them!
This may be a mixture of a bunch of different arguments. There is the anti-Nimby argument which calls out Nimbys who want an end to homelessness but vote against the construction of housing for them in their neighbourhoods. “Why don’t you house homeless people in your house?” is a much more extreme, unreasonable, and therefore less efficacious version of that idea.
There is also the more general argument (from the right) that government shouldn’t be in the business of housing the homeless. The above line then proceeds by saying that your unwillingness to invite homeless people into your house is an indication that your solution to the problem is to get other people to solve the problem for you. This may also incorporate the anti-Nimby line by further claiming that what you really want is an “out of sight, out of mind” solution to homelessness.