Using all caps for the name of a struct defined in code that includes a constructor will cause the build of the project to fail in Visual Studio. The error that is given suggests that a semi-colon is missing, and points to the line where the struct's constructor is located.
This is possibly related to [Link Removed].
REGRESSION:
Yes. This would build without any problems in 4.14.3.
USTRUCT(BlueprintType) struct FTESTSTRUCT { GENERATED_USTRUCT_BODY() FTESTSTRUCT() {} };
RESULT:
The build fails with the following error on the line of the struct's constructor: error : Unexpected '}'. Did you miss a semi-colon?
EXPECTED:
The build completes successfully.
WORKAROUND:
Do not use all caps in the name of the struct. If any letter in the struct's name is not capitalized, the project will build successfully. The build also completes successfully if no constructor is included in the struct.
Head over to the existing Questions & Answers thread and let us know what's up.
0 |
Component | UE - Foundation - Cpp Tools - UnrealHeaderTool |
---|---|
Affects Versions | 4.15.2, 4.16, 4.17 |
Target Fix | 4.18 |
Created | May 11, 2017 |
---|---|
Resolved | Aug 30, 2017 |
Updated | Sep 26, 2017 |
3561 - projectgheist |