mysqld-gdb.py
def mem_root_deque_to_list(deque):
    """convert mem_root_deque to list of python"""
    out_list = []
    elttype = deque.type.template_argument(0)
    elements = deque['block_elements']
    start = deque['m_begin_idx']
    end = deque['m_end_idx']
    blocks = deque['m_blocks']

    p = start
    while p != end:
        elt = blocks[p / elements]['elements'][p % elements]
        out_list.append(elt)
        p += 1

    return out_list
convert mem_root_deque to list of python
convert mem_root_deque to list of python
convert mem_root_deque to list of python
def mem_root_deque_to_list(deque):
    out_list = []
    elttype = deque.type.template_argument(0)
    elements = deque['block_elements']
    start = deque['m_begin_idx']
    end = deque['m_end_idx']
    blocks = deque['m_blocks']
    p = start
    while p != end:
        elt = blocks[p / elements]['elements'][p % elements]
        out_list.append(elt)
        p += 1
    return out_list
def mem_root_deque_to_list ( deque ) : out_list = [ ] elttype = deque . type . template_argument ( 0 ) elements = deque [ 'block_elements' ] start = deque [ 'm_begin_idx' ] end = deque [ 'm_end_idx' ] blocks = deque [ 'm_blocks' ] p = start while p != end : elt = blocks [ p / elements ] [ 'elements' ] [ p % elements ] out_list . append ( elt ) p += 1 return out_list
convert mem_root_deque to list of python
convert mem_root_deque to list of python
"""convert mem_root_deque to list of python"""
deque