Permalink
Browse files

adjust the interface design; super::gc_mark is always guaranteed to e…

…xist
  • Loading branch information...
kazuho committed Mar 23, 2012
1 parent 028eb31 commit 3fb96b991313ec3df3d3bbae82ebb20cebaf61b3
Showing with 2 additions and 0 deletions.
  1. +2 −0 test.cpp
View
@@ -5,10 +5,12 @@
using namespace std;
struct Label : public picogc::gc_object {
+ typedef picogc::gc_object super;
string label_;
picogc::member<Label> linked_;
Label(const string& label) : label_(label), linked_(NULL) {}
virtual void gc_mark(picogc::gc* gc) {
+ super::gc_mark(gc);
gc->mark(linked_);
}
virtual void gc_destroy() {

0 comments on commit 3fb96b9

Please sign in to comment.