title: C++ wrapper with same name?
body: <p>How can I do a wrapper function which calls another function with exactly same name and parameters as the wrapper function itself in global namespace?</p>
  
  <p>For example I have in A.h foo(int bar); and in A.cpp its implementation, and in B.h foo(int bar); and in B.cpp foo(int bar) { foo(bar) }</p>
  
  <p>I want that the B.cpp's foo(bar) calls A.h's foo(int bar), not recursively itself. </p>
  
  <p>How can I do this? I don't want to rename foo.</p>
  
  <p><strong>Update:</strong></p>
  
  <p>A.h is in global namespace and I cannot change it, so I guess using namespaces is not an option?</p>
  
  <p><strong>Update:</strong></p>
  
  <p>Namespaces solve the problem. I did not know you can call global namespace function with ::foo()</p>