title: C++ Override a pure virtual method with reference to an abstract class as a parameter by method that takes non abstract sub-class as parameter
body: <p>I have the following code:</p>
  <pre><code>struct A{ f()=0; };
  struct Aa : A{ f(){} };
  struct B{
     void foo(A&amp;)=0;
  };
  struct Bb : B{
     void foo(Aa&amp;);
  };
  </code></pre>
  <p>Right now I can't create a <code>Bb</code> class instance since I didn't override <code>foo</code> from class <code>B</code> with demanded parameter.  How can I make it work?</p>