I initially wrote a more basic response, but this is a touchy subject and requires a more in-depth response.
I've learned is that many Swedes, at the very least, are truly concerned about the concept of Swedish identity and there is a belief even among otherwise progressive Swedes that their identity is being threatened by the influx of religious and racial minorities. They use words like "they don't necessarily understand us" or "we should not have to change because of newcomers". To me, living in a western nation that has accepted millions and millions of immigrants, even over the course of my life, I find this to be frighteningly racist.
It should tell you something that even otherwise progressive people are concerned about it. The opinion of actual racists aren't worthy of taking into account in a logical conversation, but the opinions of moderate people are. Their concerns are legitimate. Honestly, I find it surprising that not only do you find such a mild remark like "they don't necessarily understand us" racist, but you find it
frighteningly racist. That's quite a level headed response to a disatrous situation.
In Canada, the idea of new immigrants is not usually as widely decried. There's a rise in anti-immigration populism here, of course, but it's not gaining traction at the same speed as it did in Europe or in the USA. But we very proudly look at the wave of immigrants that came here even in the last 40 years - the Vietnamese and Laotian and Cambodians of the 70s, the Lebanese and Egyptians of the 80s, the Serbians and Croatians and Bosnians of the 90s, the Indians and Pakistanis of the 00s, and now the Syrians and Africans of the 10s.
There's a difference between the immigrant situation in Canada and the one in Sweden. Muslims only make up about 3% of Canada's population, while it makes up about 10% of Sweden's population. That's a sizable gap. Behaviours of Muslim minorities have a more profound influence on Swedes' views of immigrants.
They're all integrating here, and maybe changing Canada a bit, but that's not a bad thing...national identities should be strong enough to entice newcomers to join them and to withstand the change of population.
I don't buy this. Non-integration is a massive problem when immigration happens in heaps. Not to mention the fact that birth rates in emigrating countries are much higher than the ones in the countries they migrate to, which results in higher population growth among minorities in developed countries. This is true both for Sweden and Canada. If mass immigration, high birth rates and non-integration tendencies cross paths, you'll definitely see massive change to the national identity, whatever you take that to mean. This depends on who it is that's doing the migrating. Turkey currently hosts the highest number of refugees in the world, mainly Syrian, Iraqi and Afghan ones. Obviously Muslim refugees would have an easier time integrating into another Muslim country, right? Nope. Their integration has been a total disaster and they've managed to alienate even devout Muslims in the country. Some of them obviously integrate properly, but I can't say they're in the majority. This change of population doesn't even have to be international, intranational population change can cause massive identity changes in locations. There are countless examples I can cite from my country on this.
And what I have tried to say, maybe not successfully, to my Swedish family is something along the lines of, "If being Swedish is so great, it will survive a few thousand brown people worshipping a mildly different god.
And this is where I went, and I apologize in advance for taking a rather smug attitude, "Oh you have no idea". Muslims don't simply "worship a mildly different god". Above everything else, devoutness among Muslims is significantly, and I mean by a cliff, higher than it is among Canadians or Swedes. Canada and Sweden are two of the least religious countries on the planet. There are cultural Muslims the same way there are cultural Christians yes, but the percentages are vastly different. The number of Islamic fundamentalists isn't negligible like the number of Christian fundamentalists are, and this is, again, especially true for countries like Canada and Sweden.
I live in a country with a 90% Muslim population. I've seen as many moderate Muslims as I have devout Muslims so I'm not oblivious to their existence. But the number of fundamentalists is also significantly high. And this is one of the most secular Muslim countries we're talking about, probably the most secular one that's not located in Southeast Asia. And the compatibility of fundamental, even devout Muslims is always going to be problematic for developed Western nations. They're never going to respect LGBT rights. They're never going to respect women's rights. They're never going to respect your pubs and they sure as hell won't be for the legalization of marijuana. They won't stop thinking your lack of sexual repression (or modesty, as they call it) is immoral. They won't stop uttering words of repent to themselves when they see a girl in shorts on the street, you just won't hear them. They're never going to stop thinking you're immoral. Their motive for being there is opportunity, and only that. There's a reason Turks in Germany, who have been there for decades, vote SDP in Germany and then do victory marches on the streets when Erdoğan wins in Turkey.
Cultural Muslims, moderate Muslims, non-religious people from Muslim countries are not a problem and never will be a problem. But the core of the issue will never be understood until progressives in the West draw a distinction between people in Muslim countries and address the issues without sugarcoating them. It's not racist to be concerned about your safety, and to be concerned about the social progress you have made being disrespected by people who come to your country because you've provided them an opportunity.