Shame is a an inherent hedge to selfishness. It's a counter balance back to the good of the whole vs everyone's natural self interest.
We as society have incorporated shame into almost all our forms of discipline. Shame isn't inherent in correction or discipline, it's just been placed there for so long we think it's natural.
This practice is so ubiquitous that any action that requires correction is seen as shame worthy. This means that making a mistake is treated as if it is selfishness. Failure is assumed to be done on purpose for the person's own nefarious motives. How is a mistake a crime against the greater good? We literally make people who try and fail out to be social pariahs, and we don't even realize it.
On the extreme end you have athletes who miss game winning shots or just lose a particular contest and the social outcry is to shame them and fire them, and replace them with someone else. We know this is unfair but we justify it by the amount of money involved. But we do the same thing at high school and little league where the money rationalization doesn't exist, and we don't even realize it.
Worse, we do it in schools, at our jobs, to the people behind the fast food counter, the sales clerk, the guy driving that blue car, the mail man, the lady with a crying baby, and most often of all, our closest family members.