Of course I don't know the immigration law of all countries but I know for example that if you are an EU citizen and go to another EU country to work, they will usually give you a 5 year residency permit to start with. After the 5 years, you can get an unlimited one. If you are at that point on benefits, they can refuse to renew and tell you to go home.
I know that Germany will not give you citizenship if you are on benefits when you apply and they also do not allow dual in most cases.