Condividi tramite


MakeAllocator::Allocate Method

 

The new home for Visual Studio documentation is Visual Studio 2017 Documentation on docs.microsoft.com.

The latest version of this topic can be found at MakeAllocator::Allocate Method.

Supports the WRL infrastructure and is not intended to be used directly from your code.

Syntax

__forceinline void* Allocate();  

Return Value

If successful, a pointer to the allocated memory; otherwise, nullptr.

Remarks

Allocates memory and associates it with the current MakeAllocator object.

The size of the allocated memory is the size of the type specified by the current MakeAllocator template parameter.

A developer needs to override only the Allocate() method to implement a different memory allocation model.

Requirements

Header: implements.h

Namespace: Microsoft::WRL::Details

See Also

MakeAllocator Class
Microsoft::WRL::Details Namespace