There's an official defence budget, and in a democracy voters express their opinion about the state of defence spending through the ballot box.
Real democracies don't scam their citizens with a secret defence stealth tax.
There are plenty of examples of this being done all over the world, because many defence industry capabilities are pretty fungible into areas like aerospace, chip design & manufacturing, optical engineering, and so on. So an industrial policy that results in development in those areas has dual benefit.
Half the reason Silicon Valley exists is because of this sort of cross investment. It's likely Airbus wouldn't exist in its current form either without it. If it's all humming along nicely, you get good cross-feed in between too, with a lot more stable and long-term low-TRL investment on the defence side feeding into the civilian sector, and high-TRL investment producing better completed systems for the defence side.
What will be important to prove in this case is whether the UK investment in civilian nuclear power is done solely to benefit the military nuclear energy industry, or whether there is a valid and viable argument for that investment on its own. I'd be interested in seeing the research.
For the state's POV, maintaining a nuclear capability is a very sufficient argument on its own! The voters may disagree, but no state really lets voters pick national security mechanisms they'd like.