Trains with Stirling Engines?

What if trains were powered not by steam but by a hot-air engine?

It would probably have to be invented earlier, probably by Jacques Charles in a demonstration/application of his famous law. The uptake is that this engine would have to come before the internal-combustion engine becomes practical, in the early 19th century. Its effects? Trains could be smaller, making more railroads, or could be more powerful, leading to bigger trains.

Planes? Nah, that'll have to wait.

Automobiles? As fun as it would be to see Stirling-powered cars trundling up the Oregon Trail, autos at this time would be slower than a horse and sink in the mud of 19th century roads. City buses? Yeah, I could see that.