Using auto_ptr<>


class OurClass
{
        const auto_ptr<OtherObject> a;
        const auto_ptr<OtherObject> b;
    public:
        OurClass(const OtherObject &aRef, const OtherObject &bRef):
			         a(new OtherObject(aRef)),
		         	b(new OtherObject(bRef)) {};
	      	~OurClass() {};
	      	....
};