Function Realloc

Synopsis

#include <include/rapidjson/allocators.h>

template <typename T, typename A>
T * Realloc(A &a, T *old_p, size_t old_n, size_t new_n)

Description

No description yet.

Source

Lines 433-438 in include/rapidjson/allocators.h.

template<typename T, typename A>
inline T* Realloc(A& a, T* old_p, size_t old_n, size_t new_n)
{
    RAPIDJSON_NOEXCEPT_ASSERT(old_n <= SIZE_MAX / sizeof(T) && new_n <= SIZE_MAX / sizeof(T));
    return static_cast<T*>(a.Realloc(old_p, old_n * sizeof(T), new_n * sizeof(T)));
}





Add Discussion as Guest

Log in