The government of course loses money on this scheme, but the people would tear down any government that tried to revoke it. It's an important and fair middle ground between national free ride and a USA-style 'sins of the father' system. Also note that the repayment amount is nowhere near the true cost of the degree, due to Conmonwealth-supported places.
If you have time to work your way through school at current US tuition, you are probably taking courses below your level.