]> gitweb.factorcode.org Git - factor.git/blob - vm/code_roots.hpp
VM: Remove unnecessary _ suffix in constructors
[factor.git] / vm / code_roots.hpp
1 namespace factor {
2
3 struct code_root {
4   cell value;
5   bool valid;
6   factor_vm* parent;
7
8   void push() { parent->code_roots.push_back(this); }
9
10   code_root(cell value, factor_vm* parent)
11       : value(value), valid(true), parent(parent) {
12     push();
13   }
14
15   ~code_root() {
16 #ifdef FACTOR_DEBUG
17     FACTOR_ASSERT(parent->code_roots.back() == this);
18 #endif
19     parent->code_roots.pop_back();
20   }
21 };
22
23 }