RPC with TMap crashes UHT

If you define an RPC method that takes a TMap argument, it crashes UHT when parsing your header. I understand that TMaps are not supported for replication, so this should probably be a clearer error.

Running UnrealHeaderTool "OurGame\OurGame.uproject" "OurGame\Intermediate\Build\Win64\OurGameEditor\DebugGame\OurGameEditor.uhtmanifest" -LogCmds="loginit warning, logexit warning, logdatabase error" -Unattended -WarningsAsErrors
LogWindows : error : === Critical error: ===
  LowLevelFatalError [File:Engine\Source\Runtime\CoreUObject\Public\UObject\UnrealType.h] [Line: 129]
  Pure virtual not implemented (UProperty::GetCPPTypeForwardDeclaration)

Put the following in Repro.h anywhere in your source tree, and run a build:

#pragma once

#include "Repro.generated.h"

UCLASS()
class URepro : public UObject
{
	GENERATED_BODY()

	UFUNCTION(Client, Reliable, Category = "Repro")
	void Repro(const TMap<int32, int32>& Map);
};

If you include BlueprintCallable on your UFUNCTION, it provides a better error.

Hey ,

Thanks for the feedback but at this time, we do not believe that what you are describing to be a bug with the Unreal Engine. However, I have submitted a feature request to have a more descriptive error message when a user tries to use a TMap in a replicated function.

You can follow the request here:

https://issues.unrealengine.com/issue/UE-38024