How do I create UE smart pointers in C++?

I read the documentation about Uneral 5’s smart pointer library, but nowhere does it say anything about how these smart pointers can be created and Google apparently doesn’t know either.

Apparently you create shared or unique pointers by calling MakeShared | Unreal Engine Documentation or MakeUnique | Unreal Engine Documentation respectively:

TSharedPtr<SomeClass> sharedPtr = MakeShared<SomeClass>(SomeClass());
TUniquePtr<SomeClass> uniquePtr = MakeUnique<SomeClass>(SomeClass());

Good thing GitHub Copilot knew what I needed to do