Function at

Summary

#include <include/EASTL/deque.h>

(1) reference at(size_type n)

(2) const_reference at(size_type n) const

Function overload

Synopsis

#include <include/EASTL/deque.h>

reference at(size_type n)

Description

No description yet.

Source

Lines 1561-1573 in include/EASTL/deque.h. Line 427 in include/EASTL/deque.h.

template <typename T, typename Allocator, unsigned kDequeSubarraySize>
typename deque<T, Allocator, kDequeSubarraySize>::reference
deque<T, Allocator, kDequeSubarraySize>::at(size_type n)
{
    #if EASTL_EXCEPTIONS_ENABLED
        if(n >= (size_type)(mItEnd - mItBegin))
            throw std::out_of_range("deque::at -- out of range");
    #elif EASTL_ASSERT_ENABLED
        if(n >= (size_type)(mItEnd - mItBegin))
            EASTL_FAIL_MSG("deque::at -- out of range");
    #endif
    return *(mItBegin.operator+((difference_type)n));
}

Synopsis

#include <include/EASTL/deque.h>

const_reference at(size_type n) const

Description

No description yet.

Source

Lines 1576-1588 in include/EASTL/deque.h. Line 428 in include/EASTL/deque.h.

template <typename T, typename Allocator, unsigned kDequeSubarraySize>
typename deque<T, Allocator, kDequeSubarraySize>::const_reference
deque<T, Allocator, kDequeSubarraySize>::at(size_type n) const
{
    #if EASTL_EXCEPTIONS_ENABLED
        if(n >= (size_type)(mItEnd - mItBegin))
            throw std::out_of_range("deque::at -- out of range");
    #elif EASTL_ASSERT_ENABLED
        if(n >= (size_type)(mItEnd - mItBegin))
            EASTL_FAIL_MSG("deque::at -- out of range");
    #endif
    return *(mItBegin.operator+((difference_type)n));
}





Add Discussion as Guest

Log in