I don’t know what it is like to work as a checkout assistant in Asda, still less in an Asda warehouse. But if I did work in a company’s shops and I learned that there were better-paid jobs available in its warehouses I am pretty sure I know what I would do: apply for a job in the latter. It wouldn’t occur to me to pick up the phone to a lawyer and claim I was a victim of discrimination. But then perhaps I am not suited to life in the age of grievance politics.

Today, the Court of Appeal has ruled that Asda may be guilty of sexual discrimination in that it is paying shop staff less than warehouse staff. It isn’t that female shop-workers are paid less than male ones working alongside them and doing the same job, nor that male warehouse staff are paid more than female warehouse staff doing the same job. The ruling has been made on the basis that shop-workers are more female-dominated and warehouse staff are more male-dominated. Barring the decision being overturned in the Supreme Court – where Asda says it will now resort – it, and the other large supermarket chains, could be liable for backpay of up to £8 billion.

The effect of this ruling will be to destroy the proper workings of the labour market. If warehouse staff are paid more than shop workers then surely there is a reason for that – and not just that the people setting the wages are a bunch of sexist pigs. Beyond meeting the national living wage, employers have to offer remuneration which allows them to attract and retain staff of sufficient quality to do the job. If it proves harder to recruit staff for a warehouse, then salaries have to be raised. It is for the same reason that airline pilots are paid more than boiler engineers who in turn are paid more than refuse collectors. It is a simple case of supply and demand – it takes time and skill to train as a pilot, and therefore there are fewer potential candidates than there are refuse-collectors. Without the freedom to set wages to make allowance for the relative number of people willing to do a job, the whole labour market breaks down.

In future, it seems, wages will be set not by the ability to recruit staff but by the ruling of a bunch of busybodies at an employment tribunal as to what constitutes ‘work of equal value’ – whatever that means. It sounds a bit like the kid at my school who used to spend much of his time boasting ‘I bet my Dad works harder than yours’.

The implication is that from now on all employers will have to second-guess which jobs an employment tribunal might in future decide are equal. Get it wrong, and they could face a bill for billions. That does not exactly sound like the business-friendly environment which the government keeps spouting about.

In eight weeks’ time, barring delay or the overturning of article 50, Britain will be free of having to obey EU directives on employment. Yet the equal pay rules didn’t come from Brussels – they were dreamed up in Whitehall. We have imposed on ourselves legislation which is as daft, as injurious to the labour market, as anything imposed on us through the EU social chapter. If this is how we are going to go about attracting business and investment as we try to make our own way in the world we are not going to get very far.