Pretty much anyone over the age of about 50 will be able to demonstrate a discrimination case. It is normal to have more urinary frequency above that age, and thus it is age discrimination as well. And sex discrimination given that a male might be able to, er, use, a bottle under their coat.
If the railway is doing anything other than letting people alight to use the loo or use another train, they need hitting with some legal cases.
Yes, some trains don't have toilets. But one should be able to expect that where they are normally provided they are working, and if not arrangements to be made for any passenger needing one to use one.
"Pay a whackload extra or wet your pants" is not something it is acceptable for any business to even suggest.