VS 2022 seems to be using an incompatible compiler version. I know because when I compile my code (it fails with code 6), I get this message in the log file:
Detected compiler newer than Visual Studio 2022, please update min version checking in WindowsPlatformCompilerSetup.h
From what I've seen, the compiler setting is supposed to be in project > Project Properties > General, but when I look there, that option isn't shown. The screenshot below is all I see.

My guess is maybe I need to install some optional module with the installer, but I can't find anything about that.