std::shared_ptr::operator bool

From Cppreference

Jump to: navigation, search
operator bool() const;

Checks if *this manages an object, i.e. whether get() != 0.

Contents

[edit] Parameters

(none)

[edit] Return value

true if *this manages an object, false otherwise.

[edit] Example

[edit] See also

get
returns a pointer to the managed object
(public member function)