UE 5.2 Packaging failed

Please see this previous thread about a very similar compiler error:

To start, you probably need to make sure you’re on the latest version of Visual Studio 2019.