It's never happened to me in my car. I'm always on top of that kind of thing.
About 10 yrs ago, I was driving with a friend and we managed to barely coast off the road (on fumes).
I just whipped out my cell phone, called a cab who drove us to the nearest gas station where we filled up a jug, and drove us back to the car, where we poured the jug in, ...and then drove on to the gas station to fill up the tank.