title: Building in Release mode requires other project lib file but Debug mode doesn't
body: <p>I've got two projects in a C++ project. Building in debug mode works fine however it fails in Release mode when linking. Essentially, it seems that each project requires the other's lib file (circular dependency)?</p>
  
  <p>Is there a reason why this would only be an issue in relase mode? Perhaps optimisation?</p>
  
  <p>What I'm doing:</p>
  
  <p>Project A has base type ABase.
  Project B has base type DerivedFromABase (which is derived from ABase). It includes ProjectA\ABase.h as a result. So project B has a dependency on project A.</p>
  
  <p>In Project A, there is a file, Process.cpp. This file uses pointers to ABase, which can be of type ABase or DerivedFromABase (though all are cast as pointers to ABase).</p>
  
  <p>If I include project B's DerivedFromABase.h in project A's Process.cpp, project A now seems to need project B's lib file, <strong>but only in Release mode</strong>. This happens even when never explicitly using the DerivedFromABase class. Debug mode compiles with no issues.</p>
  
  <p>EDIT: I'm not necessarily interested in workarounds to get it to work. This was just a quick hack to test a new feature (these projects are two of many) - I'm in the process of refactoring the code to implement it properly, so that project A need not know about DerivedFromABase. I'm interested in why it works in Debug and not Release.</p>