That said, obviously, thanks to refrigeration and freezing, we have the capability of storing a much broader range of foods in a healthier way for longer periods of time, assuming that whatever disaster we face doesn't cause the electrical supply to become transient.
I am extremely skeptical that we'd deal with a similar event any better. We've optimized too much for efficiency and just-in-time delivery.
A good rule of thumb is if the can isn't deformed as a result of the volume of its contents changing as result of a chemical reaction then you're good to go. As far as rules of thumb go this is a pretty good one because a chemical reaction is a necessary perquisite of food spoilage (if the food doesn't change it doesn't spoil) and said chemical reaction will almost certainly alter the volume (at STP) of the contents of the can thereby deforming it. You can also use your nose which has millions of years of incremental improvement making it good at telling you what is and isn't edible.
OTOH I've cooked and eaten eggs 3 weeks after the date, with no noticeable difference in taste or texture.
OTOH, if you buy a bottle of milk and let it sit unopened for 5 days, then start consuming it, you'll usually find that it lasts roughly 5 days past the best before date.
To give some perspective check out Steve1989MREInfo's Youtube channel [0], where he routinely ingests food from cans dating as far back as the world wars. Although you might argue he has a built up immumity by now giving the amount of bad food he must have eaten.
Canned goods, on the other hand, should last indefinitely so long as the can itself doesn't fail. There's just not a whole lot of relevant chemistry going on in a sterile, low oxygen environment. I suppose permeability of the can itself to oxygen (depending on what method was used to seal it) could become relevant on a long enough timescale, but if the contents are truly sterile even that shouldn't make much difference.
If anything does happen to the contents of the can, as noted in another comment there will almost certainly be a visible change in volume (ie the can will deform).
Lower birth rates (due to birth control, affluence) is the fundamental change.