So if you tell someone your salary, your job probably feels more difficult to you than it looks to them, and you probably feel more productive than they think you are. If you make the same or more than they do, there is a very high risk that they will think you are overpaid.
This is obviously a risk to the company, which is why most companies (at least in the US) have a policy against it. But it is also a risk to you and your relationship with that other person, which is why few people share their salary information with their friends.
You are right that this is a fundamental problem for equality. But it is not an easy or safe thing to change, which means it will take a lot of time and effort.
I am not saying that the status quo should remain. I'm just pointing out the reason it is difficult to change.
(Don't Call Yourself a Programmer: www.kalzumeus.com/2011/10/28/dont-call-yourself-a-programmer/)
What's amazing to me is that every company I've ever known of has a policy along those lines, yet it is illegal to sanction employees for talking about their pay with coworkers under the National Labor Relations Act and has been for a long, long time.
I also wonder to what extent the jealousy argument applies in the real world. It makes sense, and I'm sympathetic to it, but I've worked at two jobs where it was pretty well known what everyone made. There were huge disparities in what people made for doing the same work in both cases. It didn't cause any resentment issues I know of - but I suspect it did make people more likely to ask for a raise when they knew what was possible, which I think is the problem that management really has with it, because it becomes much harder for them to justify to the employee why they can't or won't pay them more, even though there may be valid reasons for it.
The invisible hand of the market will lead prople to companies with the highest value for X2, which are usually also those where the productivity (i.e. contribution to company revenue) per person is highest.
This has two effects (1) Saves me a lot of time on the negotiation front. If the announcement doesn't pay what you want, don't apply to it. Saves me and the hiring manager a lot of wasted time if I were to apply to a post thinking I'll get paid $X when it will really pay $Y. And (2) Since it's all public anyway, everyone knows that if you want to make $X then you need to train into position Y and you have a pretty concrete list of knowledge/skills that you can hack away on to achieve that. None of this blind guess work.
[I have no explanation for why she stayed there for 9 years]
Their salaries gave me the incentive to demand a big raise from my employer. Which I did and didn't get, so I quit and got myself a much better paid job.
These policies are actually often illegal due to the National Labor Relations Act.
[$67/hr, 2 years of experience, senior frontend engineer, Palo Alto]
If OTOH you're not billing 160 hours a month or you're not getting the standard benefits (healthcare, etc), then you're contracting whether you describe yourself as a contractor or not, so the objection would stand in that case.
(This distinction made for the benefits of other HNers, since I have from time-to-time run into people who think they are employees but who are actually consultants who just happen to have a very thin client list and substandard rates.)
Personally, I'm at the point where I don't care as much about the money, it's more about the people I work with. For those not at my point though is why I provide salary info though - it is a nice data point to use to assess for others.
[$46/hr, 5 years of experience, Software Engineer, Boston]
[38K, ~15years experience, tiny non-technical startup in London]
I started out making 10% more than what I was initially offered since I knew what coworkers with similar experience made and asked for that amount. And I know what coworkers with much more experience (10+ years to my 2 years) make, so I can gauge whether I am on the right track.
Company culture of not talking about earnings only helps the company. It allows them to pay lowest market value for anyone, under the (often true) hopes that they don't know their value. In short talk about it, and get other people to talk about it.
I would talk with your co-workers get them to open up about what they make, or have the breach subject in the conversation group while the other person can hear. Talk about what you used to make and what you make now. The key if to give everyone more context. Its important to remember that someones value as a person is not their market price.
The more information a person has available, the better the choices they can make.
[$47/hr, 2 years out of college, east coast]