Skip to content

LiteFX::makeUnique

Creates a new unique pointer.

Synopses

Declared in <litefx/containers.hpp>

Creates a new unique pointer.

template<class T>
[[nodiscard]] constexpr UniquePtr<T> makeUnique();

» more...

Creates a new unique pointer.

template<
    class T,
    class... TArgs>
[[nodiscard]] constexpr UniquePtr<T> makeUnique(TArgs&&... _args);

» more...

Return Value

A new unique pointer.

Note

The return value should not be discarded.

Template Parameters

NameDescription
TThe type of the object, the pointer points to.