Boost C++ Libraries Home Libraries People FAQ More

PrevUpHomeNext
value::if_uint64 (2 of 2 overloads)

Return a uint64_t pointer if this is an unsigned integer, else return nullptr

Synopsis
std::uint64_t*
if_uint64();
Description

If this->kind() == kind::uint64, returns a pointer to the underlying unsigned integer. Otherwise, returns nullptr.

Example

The return value is used in both a boolean context and to assign a variable:

if( auto p = jv.if_uint64() )
    return *p;
Complexity

Constant.

Exception Safety

No-throw guarantee.


PrevUpHomeNext