(I'm not on the market now, but I'm 43, my coworker is 41 or 42 I think, and virtually every programmer friend/cohort I know of that's 40+ is still gainfully employed)
If you've mastered C, you're still in decent shape.
I'm in France at the moment. Maybe this whole "developers have to be [..30] years old" is only the norm in the niche HN talks about most.
I work in sales and pushing 50 but have no kids or wife. I am spending most the day today drinking coffee and trying to learn to think in functional javascript.
The day just does not look like this when I am in a relationship. I can't even imagine if you throw kids in the mix. If I had a kid I would be spending my time wiring up their brain instead of trying to rewire my own.