title: Should a helper function go in the header or in the implementation file?
body: <p>When writing a helper method for a class in C++, should it be declared as a private method in the class's definition in the header (.h) file? For example:</p>
  
  <pre><code>/*Foo.h*/
  class Foo {
  
       public:
           int bar();
  
       private:
           int helper();
  };
  ...
  /*Foo.cpp*/
  ...
  int foo::bar() {
      int something = this-&gt;helper();
  }
  
  int foo::helper() {
      ...
  }
  </code></pre>
  
  <p>Or alternatively, is it better not to declare it as a private member of the class, and instead just make it a free-standing function in the implementation?</p>
  
  <pre><code>/*Foo.h*/
  class Foo {
      public:
          int bar();
  };
  ...
  /*Foo.cpp*/
  ...
  int Foo::bar() {
      int something = helper();
      ...
  }
  
  int helper() {
      ...   
  }
  </code></pre>