std::pointer_traits<Ptr>::to_address

Header: <memory>

Constructs a raw pointer that references the same object as its pointer-like (“fancy pointer”) argument.

# Declarations

static element_type* to_address( pointer p ) noexcept;

(since C++20) (optional member of program-defined specialization)

# Parameters

# Return value

A raw pointer of the type element_type* that references the same memory location as the argument p.

# See also