Don't know about pilots, but I'd think doctors and actors are near the extreme ends of the age discrimination spectrum. Ie. being an old doctor makes you credible, being an old actor (or especially actress) severely impinges on your options and expectations. Being an old developer is probably somewhere in between.
Pilots retire at the mandatory retirement age of 65, which a friend of mine will do next year. He'd rather keep flying and I imagine his employer would prefer that too, given the pilot shortage. But he will also admit that the job his harder on him now than it was when he was 25, so the rule arguably makes sense.
Unfortunately in many places of the US this is starting to change. Companies like Advent Health (used to be Florida Hospital) have been seizing control of medical practices from the doctors.
The common scheme is to offer logistical support (dealing with paperwork, IT, etc) in exchange for joining under their umbrella (with the implicit or sometimes not so implicit promise that otherwise they exert no influence over the operation of the practice). Then after a few months to a year they start making sweeping changes restricting what patients the doctor is allowed to see, what treatments they are allowed to provide or suggest, how much they can charge, and where they are allowed to see or treat their patients. Essentially resting any autonomy the doctors had over their practice.
This is what happened to our PCP and many other doctors in Florida. They were given an ultimatum and any patients who didn't fit the profile Advent had selected for them were forced to leave them for some other doctor.
Nowadays the only doctors with any "real" autonomy are surgeons and even then the actual autonomy they have is being increasingly encroached upon.
I'm not sure how common this is in other regions but at least in Florida it is becoming increasingly difficult to find Doctors who haven't been effectively tricked into forfeiting control of their practices and reduced to employees for large corporations.