I don't think that's true? Admittedly You could perhaps parse the statute[0] in a way that might imply it. But I think the point is that if you give aid and comfort to an enemy of the United States that you fall under the definition regardless of whether you are officially in a war or not.