Forward declaration not working on UPROPERTY enum

My project compiles ok when I forward declare as you have done…

enum class EMyEnum : uint8; 

It only failed when I copied your code and put it into a TArray with a pointer, but the error wasn’t regarding the enum…

Inappropriate '*' on variable of type 'TArray', cannot have an exposed pointer to this type

Are you sure you want a pointer on your TArray? Because other than that it works for me (with a UPROPERTY)

1 Like