83 m_stack->
retarget((*rhs.m_stack)[rhs.m_index], m_index);
105 return m_stack->m_vector[m_index];
111 unsigned int m_index;
114 : m_stack(stack), m_index(index)
136 : m_nodestack(stack),
138 m_next_scope(stack->m_innermost_scope),
140 m_saved_size(m_nodestack->
size())
143 stack->m_innermost_scope =
this;
150 if (
this != m_nodestack->m_innermost_scope)
153 m_nodestack->
resize(m_saved_size);
155 m_nodestack->m_innermost_scope = m_next_scope;
173 size_t startSize()
const
178 static void nestingError();
219 return m_vector[index];
275 void pop(
unsigned int count = 1);
277 void pop(
unsigned int count = 1)
301 unsigned int index = m_vector.size();
302 m_vector.push_back(node);
329 if (index < m_protected_count)
330 retarget_aux(m_vector[index], node);
331 m_vector[index] = node;
345 if (new_size >= m_protected_count)
346 m_vector.resize(new_size, 0);
347 else resize_aux(new_size);
356 return m_vector.size();
381 std::vector<RObject*> m_vector;
382 size_t m_protected_count;
389 Scope* m_innermost_scope;
395 __attribute__((hot,fastcall))
402 __attribute__((hot,fastcall))
404 void resize_aux(
size_t new_size);
408 #endif // NODESTACK_H