The United States for the first century or so had open immigration, but citizenship was restricted to "free white person(s)" of good character. The distinction between citizen and resident is therefore quite old, but originally open immigration was simply taken for granted. Immigration police didn't exist, nor police generally. So on the one hand, there wasn't even a hope of enforcing an immigration law, there also wasn't much in the way of government services. We've always had a distinction, but it was originally pretty arbitrary, racially biased, and mostly irrelevant, and the context has entirely changed. I'm not sure what conclusions may be drawn from that.
Other than violating many Constitutions you mean? It's bad enough to have invisible castes as is, now enshrining it into law would be a regression.