$include_dir="/home/hyper-archives/boost-users/include"; include("$include_dir/msg-header.inc") ?>
From: Johan Råde (rade_at_[hidden])
Date: 2006-11-20 10:39:24
Martin Waller wrote:
> #include <MyClass.hpp>
> #include <someOtherClass.hpp>
>
> MyClass::MyClass()
> {
> init();
> }
>
> void MyClass::init()
> {
> spOther(new someOtherClass(this));
You can not call a constructor here.
spOther has already been default constructed.
Instead you should use the reset member function:
spOther.reset(new someOtherClass(this));
> }
>
>
>