Also i believe that the country is first and foremost, a landmass - with geological, hydrological etc features defining their resource base and transportation abilities and thus what they can do and what they can't, and what's optimal for them, plus a political system that is built to make the optimal use for the former. Gradual replacement of people with another can still keep all of it in place and maintain qualities of a nation from the standpoint of average consumer as more or less the same.
Plus, if you invite immigrants, you get to pick the best of them, so probably you won't harm your overall population quality.