Before the introduction of the European working time directive (EWTD) for junior doctors in 2004, it was not uncommon for us to work in excess of 100-hour weeks. People who trained under these conditions talk candidly about falling asleep in theatre. So I am in no doubt that the directive has saved many lives.

Yet only a couple of weeks ago, David Cameron said the EWTD should never have been introduced. One of the reasons he gave was "it affects the way we run our hospitals". Now, following the collapse of talks in Europe on revisions to the directive, the newly launched Conservative group Fresh Start is calling for the UK to negotiate a complete opt-out from all existing EU social and employment legislation.

The EWTD and how it applies to junior doctors now seems to be the "go to" example to illustrate how European legislation is damaging the UK. The directive applies to most UK workers unless they have opted out. The rationale for excluding junior doctors from the working time directive is a strange one. There is clear evidence that tired people make more mistakes. While that may not matter too much if you work in an office or a shop, it can mean the difference between life and death if you work in a hospital.

Of course the prime minister is not talking about going back to the days of 100-hour weeks. The clarion call is for greater flexibility. The problem with this argument is it assumes that hours are set in stone. In reality the directive is flexible: the 48-hour week is averaged out over 26 weeks so that it is possible, and indeed commonplace, to work longer hours some weeks. So junior doctors do not down tools when they have reached a limit. We are professionals who stay with a patient until it is safe to hand over the responsibility to other doctors. Furthermore, some services were also allowed to delay the introduction of the directive, if the hospital thought it threatened patient safety.

Reducing junior doctors' working hours has presented the NHS with the challenge of training doctors in shorter working hours. Many junior doctors feel that the reduction in working hours has damaged their training, but it is difficult to argue that this is the fault of the directive. It was not introduced overnight. In fact, the NHS had the best part of a decade to prepare for its introduction. In August 2000, a timetable was set to incorporate junior doctors into the directive. Limits on working hours were slowly introduced first to 58 hours, then 56 and then finally 48 in 2009. The problems are largely a result of poor implementation.

In response to concerns raised by the British Medical Association and the medical royal colleges, an independent review was commissioned to look at the impact of the EWTD on training. The 2010 report, called Time for Training, concluded that high-quality training can be delivered within the reduced number of hours, and that current problems will not be solved by either increasing hours or lengthening training programmes.

The focus on overturning the directive is an unnecessary distraction. We should instead be focusing on implementing the recommendations of the Time for Training review. Hospitals have remained reliant on junior doctors to provide out-of-hours services for too long. If our working patterns are dominated by night shifts, we inevitably miss out on training. We need to reduce the time junior doctors spend on administrative tasks that take us away from patients and opportunities to learn. Most importantly, the NHS needs to move to a consultant-based system that will deliver high-quality care and give junior doctors time to train.

Somehow, junior doctors seem to have become a pawn in the political argument about the powers of the EU. I resent my working hours being used as a stick to beat Brussels, especially when the argument is flawed. Longer working hours are not a panacea that will solve the problem of providing high-quality training in a shorter working week, and politicians should stop acting like it is.