not familiar with smart pointers. assign variable to value returned from function

auto_ptr<a> b()
{
return auto_ptr<a>(new a)
}

auto_ptr<a> c = b()

Kuphryn