The rich countries are aging fast but they are rich. China on the other hand has a race with time on its hands. It needs to grow rich enough benfore it ages to an order similar to that of the richer countries. Interestingly india ad sub saharan africa are aging much less speedily than china and will be quite young as a population even in 2050 while china would have reached the average age of the rich world by then. This means the vigor of economic growth may last longer in these regions than in china if they get their act together in governance and avoidance of civil wars.
I dont know about sub saharan africa but for india it is comforting to know that it has a fair shot at prosperity of the sort enjoyed in today's rich world. China is less lucky in this matter owing to its current age profile and also sex ratio. How did this happen? Simple answer is - effectiveness of its one child policy. That policy worked quite well when launched and is now coming back to hurt china.
I look back at india's own obsession with population control in the 80s (the forced sterilizations in the indir gandhi era being a case in point). Two good things about india's push for the population control were its focus on two children as against one and its democracy which avoided a very tight implementation of the initiative. Over time most parents acted smart enough anyway and had only two children. Of my three siblings two have two children each and one has one. Of all my cousins only two (out of 20) have more than two childern. All my uncles had more than 4 children. I guess within a generation much of india moved from having 3 to 5 children as a matter to routine to having 2 and in some cases even 1. This has helped control the population grow rate without creating the worry china has i.e. aging too fast as a society.
What india makes of this demographic dividend is of course another question but having the strong tailwind of demography when the society embarks on its quest for prosperity sure does help!!