All TOptional<> Types are incomplete

Hi everyone,

I am getting a really strange issue after upgrading from a source build of UE5.4 to UE5.5, where in my Engine code and Project Code, all TOptionals are saying the type is incomplete. What is the most odd about this is everything builds just fine, HOWEVER, when creating an actual build of the game it does not run on certain machines anymore that it ran just fine on for 5.4.

I have verified that if I remove certain lines that hit TOptionals and cause a crash on the machines I mentioned above, it works though. Any help would be appreciated, at first I thought it was a Visual Studio issue, but after cleaning, clearing Intermediates, regenerating I am still getting the same issue.

The Crash I get on other machines :

Assertion failed: IsSet() […(Path)…\Engine\Source\Runtime\Core\Public\Misc\Optional.h] [Line: 364]
It is an error to call GetValue() on an unset TOptional. Please either check IsSet() or use Get(DefaultValue) instead.

2 Likes

Would still love an answer to this, but I was able to modify my engine source code to prevent this error from crashing builds on certain machines.

Just chiming in to say that I am also experiencing this problem. TOptional’s in my project are all marked as incomplete type "TOptional<T>" is not allowed", but my program compiles without errors and appears to run correctly.

The usual fixes for intellisense problems I have had in the past did not solve this problem: closing and reopening the visual studio solution, deleting the .vs file in the project directory, regenerating the visual studio solution; none of these fixed the issue.

I have only experienced this intellisense problem with TOptional.

July 13 2025 Edit: This problem is still present in Unreal Engine 5.6.0 with the latest Visual Studio Community version (17.14.8)

1 Like