C++ FInputModeGameAndUI CRASH when opening project

Compiling this code

    FInputModeGameAndUI inputMode;
	inputMode.SetHideCursorDuringCapture(false);
	SetInputMode(inputMode);

into MyPlayerController.cpp and restarting the editor will start crashing it on startup. I tested it on a new blank C++ project and can successfully recreate the crash every time. The only way to get back into your project is to go to your project folder, open the .sln file and remove or comment out this code then rebuild your project.

Hello,

We’ve recently made a switch to a new bug reporting method using a more structured form. Please visit the link below for more details and report the issue using the new Bug Submission Form. Feel free to continue to use this thread for community discussion around the issue.

https://epicsupport.force.com/unrealengine/s/

Thanks