Did he? The version I’m familiar with is Boulez saying Shosty was “the second, or even third, pressing of Mahler” (Shostaphobia)
A lot of modern masters that have not severed themselves completely from Common Practice are in debt to Mahler some of the time. There’s several pieces I can think of that are very close to him; Malcolm Arnold’s Symphony 2 Movt 3 is one:
John Adams’ Harmonielehre another (although the minimalism means it doesn’t quite work):
And yes, lots of people compare Shostakovich and Mahler, usually negatively. They’re both emotional in their symphonic oeuvre (although Shostakovich is rather more varied, and decidedly nonlinear in how his style changed). And Shostakovich persisted with the symphonic genre, whereas in the West Mahler was often regarded as the end of that tradition.
I’ve heard all the Mahler symphonies. I’ve heard all the Shostakovich symphonies. My favourite Shostakovich symphony is the 4th, which is clearly his most Mahlerian. But most of Shostakovich’s symphonies aren’t that Mahlerian. There’s more melancholy and vibrancy, less expansiveness and emotional journey; Shostakovich’s constructions are tighter and less sprawling; his orchestration more toned down.
Shostakovich is still operating in the same symphonic tradition as Mahler, though. The comment, as much as anything, reflects how unusual that already was by the ’30s.