Feature Request: Add ThisClass to each USTRUCT

Unreal provides a ThisClass typedef within each UCLASS and UINTERFACE type via their GENERATED_BODY() macro. However, USTRUCT types do not have this. It looks like a single line update in UhtHeaderCodeGeneratorHFile.cs at line 525 would add it easily.

builder.Append(“\ttypedef “).Append(scriptStruct.SourceName).Append(” ThisClass; \\\r\n”);

I’ve got this added locally, but my lead wanted me to check in to see if this is something you guys would be interested in adding. I’ve got it changed locally and I don’t mind submitting a pull request if this is something you guys are interested in taking.

Hi Daniel, I’ve made that change and sent it for review. I’ll let you know how it goes, but I don’t anticipate any problems.

Steve

Hi again, this has been submitted now and will be available in 6.0. Thanks for the suggestion!

Steve