But I agree with your basic premise. Sure, making partner at a white shoe New York law firm is not a bad gig if you're into it and have been OK with the insane hours to get there. I did some work for one of those firms once and got pretty well paid for it (expert witness work).
But, you could also say that being an English professor can be a pretty good gig--if you're tenured at an Ivy League college. Which doesn't mean it's actually a great career choice given you're more likely to be teaching as an adjunct at a couple different community colleges or in a public high school with your expensive PhD.
[1] "Disbarment is quite rare: in 2011, only 1,046 lawyers were disbarred." https://en.wikipedia.org/wiki/Disbarment [2] https://www.rocketlawyer.com/blog/getting-disbarred-is-harde...
That kind of risk just doesn't really exist in software engineering beyond regular criminal background checks.
During the time they're making that much money they're basically trapped working insane hours at one firm. Most lawyers don't even make six figures. Also, they can get disbarred if they make a mistake.
Software engineering allows for higher earnings for your entire career (though the ceiling might be lower on earnings), is less stressful and doesn't demand as many hours (in general) doesn't have a regulatory body that can take away your right to work if you get in trouble.