BR▸ Rule Book from 1964 ...
161: When ladies are travelling alone the staff must, if requested, endeavour to select a compartment for them (according to the class of their tickets) in which other ladies are travelling. If ladies wish to change compartments during the journey, the staff must enable them to do so.
I don't know when this was withdrawn but I hadn't realised this was still on the books so recently - that's recently for some of us!

Remember "
Life on Mars" was set in the 1970's!
Does "Ladies" include the David Walliams sort of "ladies"? ("I am lady, I have a lady's ticket, and I would like a lady's seat in a ladies' compartment in a ladies' carriage. From a lady's station, if you don't mind.)
I do not, however, see how a government of any colour, except the black of Isis (shudder), could enforce such segregation on gender grounds without risking a humiliating defeat in the high court, let alone Strasbourg. To hear a junior minister say she may even think about it makes me think there must be an election in the offing.
You heard it here first. To the Hustings, sisters! Allow me to hold the door for you, my dear...