how to call a function when auto_ptr is a parameter of it!
<pre><code>#include &lt;iostream&gt;
#include &lt;memory&gt;

class test
{
     private:
         int x , y;
     public:
         test(int a , int b):x(a),y(b){}
         void fun()
         {
            std::cout&lt;&lt; x&lt;&lt;" "&lt;&lt;y&lt;&lt;" "&lt;&lt;std::endl;
         }
};

void show(std::auto_ptr&lt;test&gt; t1)
{
    t1-&gt;fun();
}

int main()
{

    show(new test(3,4));

}
</code></pre>

<p>I am getting a compilation error , please tell me what's wrong in this code?Thanks in advance.</p>
