I used to believe that too. However, after years in academia, I am not so sure.
It appears to me that much of the research money spent in the universities is wasted. Perhaps worse, the universities, in their lust for government research money, have neglected teaching.
Do we want to miss this technical advances? I don't think our military can afford not to subsidize pure and applied science.
I do not doubt that the government has an obligation to fund military research.
I am a little biased, though, as someone who earned a B.S. in Chemistry.
My degrees are in Chemical Engineering.
Some professors have. Some still realize their primary function is to teach students. I still am in touch with one of those, even though I no longer use my Chemistry degree.