There may be some truth to what your mechanic said, however my opinion is different.
My opinion is better fuels and oils.
The leaded fuels of yesteryear really made hard carbon deposits in the cylinder, of which numerous particles made it past the rings and into the oil. These very hard particles acted like microscopic sand paper that constantly wore down the rings, cylinder walls and bearings.
Lead free gas leaves a black sooty deposit in the combustion chamber and is practically non-abrasive.
By removing that “sand paper” along with modern oils, I think the engine life is about 3 times that of a few decades ago.
I did not know that. Fascinating.