Warning reference will be nullptred bug

Update again. So it appears the culprit code triggering the issue is this

#if WITH_HOT_RELOAD
			// Mark existing class as no longer constructed and collapse the Children list so that it gets rebuilt upon registration
			if (ClassToHotReload)
			{
				ClassToHotReload->ClassFlags &= ~CLASS_Constructed;
				for (UField* Child = ClassToHotReload->Children; Child; )
				{
					UField* NextChild = Child->Next;
					Child->Next = nullptr;
					Child = NextChild;
				}
				ClassToHotReload->Children = nullptr;
			}
#endif

in UObjectBase.cpp, UObjectCompiledInDefer. I am not sure what ‘rebuilt upon registration’ is referring to, so can’t infer whether this is the correct behavior, and something later is failing, or if there is simply a bug in this bit of code. Perhaps it is supposed to be added to the “DeferredCompiledInRegistration” list?

It appears that commenting out the clearing of the child list (but leaving in the clear of the constructed flag) fixes the problem, at least in my minor test case. Whether it survives across more of the project remains to be seen.

Hopefully the unreal team could now take a look and work out what the proper fix is? :slight_smile:

cheers