This problem was identified in nursing years ago (inverse). Nursing has great opportunities for growth, pay roughly equivalent to programming and shortages in every state so severe states are starting governmental programs just to get more nurses... yet less than 7% of nurses are men due to a variety of reasons, but the major one is lack of role models. Despite identifying it and trying to offset it, male nurses are still exceptional rare because they never broke critical mass on role models.
In 4.5 years on 3 different projects (SRE team, dev team, different dev team), I was all alone. I should tally up all of the names of my coworkers and see just how it worked out. People came and went but it was always guys replacing guys.
It's a shame they don't release the numbers because it's easy for "40%" to float around the Zeitgeist, concealing a very real problem.