conversions in C++
<p>I have this snippet of the code:</p>

<h3>header</h3>

<pre><code>class A {
private:
    int player;
public:
    A(int initPlayer = 0);
    A(const A&amp;);
    A&amp; operator=(const A&amp;);
    ~A();
    void foo() const;
friend A&amp; operator=(A&amp; i, const A&amp; member);
};
</code></pre>

<h3>operator=</h3>

<pre><code>A&amp; operator=(A&amp; i, const A&amp; member){   
    i(member.player);
    return i;
}
</code></pre>

<p>and I have row in my code:</p>

<pre><code> i = *pa1;
</code></pre>

<p>A *pa1 = new A(a2);
at the beginning i was int</p>

<p>how can I fix it, thanks in advance
I have an error <code>must be non-static function</code></p>
