That's not really what I said at all. How does allowing someone to have gaps in their employment history mean accumulated experience should not contribute to pay?
In my opinion general "years of experience" is not a large contributing factor in regards to pay anyways. Relevant experience on specific projects using certain technologies and expertise in specific domains matters a lot more. It's supply and demand.
Someone has 10 years of continuous experience, knowledge, and work. They makes $100k.
Someone else is the same age, graduated the same year, from the same school, but took two years off of work and therefore has 8 years of experience. They make $80k, which is less than their colleague.