If anything were guaranteed to salve a bruised faith in human nature, it is the video of the dramatic rescue of a baby in Paris on Saturday. Mamoudou Gassama, a 22-year-old “sans papiers”, or undocumented migrant, from Mali, saw a lone toddler dangling from a fourth-floor balcony in the 18th arrondissement, and scampered up the outside of the building to save him, while onlookers cheered. The exploit made him famous as the “Spider-Man of the 18th”, and yesterday he went to the Elysée Palace to meet Emmanuel Macron. Awarding Gassama a medal for bravery, the president told him he would be immediately naturalised as a French citizen, and given a job with the Paris firefighters.

Macron, however, himself highlighted the contrast with France’s usual policy towards migrants. “We can’t just give papers to everyone who comes from Mali, from Burkina,” Le Parisien reported Macron as telling Gassama. “We’ll grant them asylum if they’re in danger, but not for economic reasons. But you did something exceptional. Even if you didn’t think about it, it’s an act of bravery and strength that has drawn everyone’s admiration.” It’s hard to say if Macron really intended the tone of patrician condescension to the noble savage from the former colony, but he made his general point very clear in the press conference afterwards: “An exceptional act doesn’t change politics.”

Play Video 0:35 Paris hero climbs four-storey building to rescue dangling child – video

Well, indeed. The politics of migration in France have long had ugly undertones. In last year’s presidential election, Marine Le Pen fought a campaign “in the name of the people”, the dog-whistle being that “the people” were exclusively white French. She said she was “not against immigrants, just against immigration”, implying that she would only tolerate immigrants who didn’t perform any immigration, ie stayed where they were in the first place. (She also declared, like many fascists before her, that the “enemy of the people” was “the world of finance”.) This overtly racist campaign won her second place in the first round of voting. She was handsomely beaten by Macron in the next, but still attracted more than 10 million votes.

This immigration law has exposed the brutal limits of Macron’s liberalism | Gabriel Bristow Read more

No one who knows France well was surprised. During the years I lived in Paris, also in the 18th, the atmosphere of official suspicion of migrants was ever present. I regularly saw people stopped on the street by policemen asking for their papers – but this only ever happened to those with brown or black skin. If Gassama had not heroically saved a toddler, he might very well have spent the rest of his days being harassed and detained by the cops. Even some arty metropolitan types participated in the general prejudice: I knew one or two who would, with casual mischief, refer to migrants from the Maghreb as “beurs”, derogatory backslang for “Arabes”.

Gassama himself, who made the dangerous boat crossing to Italy before arriving in France last year, was impressively modest (“It’s the first time I’ve ever won an award”), but his experience underscores how hard it is for people like him to gain acceptance in French society. Macron’s attitude, indeed, sends the message that you can only become French if you do something so extraordinary that the vast majority of French people would never even attempt it.

• Steven Poole is the author of Rethink: The Surprising History of New Ideas