PARIS — France has voted to scrap a 19th-century ban on women working at night to bring the country in line with European anti-discrimination legislation.

The ban excluded women from working at night in certain places, including factories and mines, with the aim of preserving moral and family values.

Nurses, cleaners and women working in other industries typically regarded as more feminine were exempt from the ban, which the European Court of Justice had condemned as discriminatory.

Deputies in the French National Assembly voted late Tuesday to repeal the ban two days ahead of a Nov. 30 deadline the court set.

The French decision states that night work must remain an exception and must contribute to the continuity of economic activity or services of social value.

"This will fill a real hole as far as the protection of workers is concerned," said Social Affairs Minister Elisabeth Guigou.

French government figures show that 580,000 women already work at night, principally in the health and service sectors. The figure compares with 2.14 million men.