From 3232cd164d24850123a0c231455c6efa691edba3 Mon Sep 17 00:00:00 2001 From: Daniel Burrows Date: Fri, 22 May 2009 07:55:08 -0700 Subject: Actually, take raw pointers in add_parent(). The reason here is that this will be invoked from constructors, which can't have smart pointers since the object isn't created yet. --- src/generic/problemresolver/incremental_expression.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src/generic/problemresolver/incremental_expression.h') diff --git a/src/generic/problemresolver/incremental_expression.h b/src/generic/problemresolver/incremental_expression.h index 4d77dcbb..2435f55d 100644 --- a/src/generic/problemresolver/incremental_expression.h +++ b/src/generic/problemresolver/incremental_expression.h @@ -192,9 +192,10 @@ public: // Add a weak reference to the given expression; its // child_modified() routine will be invoked when this child's value // changes. - void add_parent(const cwidget::util::ref_ptr > &parent) + void add_parent(expression_container *parent) { - parents.push_back(parent); + if(parent != NULL) + parents.push_back(parent); } virtual T get_value() = 0; -- cgit v1.2.3