title: Undefined reference to namespace::class::constructor
body: <p>I have the following code, and every time I compile, it's giving me an error saying that there is an undefined reference to ns::player::player()</p>
  
  <p>This has never happened to me before, so to be honest, I'm quite confused. I just know it's something simple. By the way, the code below isn't <em>exactly</em> the code I'm working with, but it's the same idea. I just shortened it up and changed the names to make it easier to read.</p>
  
  <p>Also, if I put it all into one file, it plays nice. </p>
  
  <p>main.cpp</p>
  
  <pre><code>#include "space.hpp"
  int main()
  {
     ns::player kyle;
     return 0;
  }
  </code></pre>
  
  <p>space.hpp</p>
  
  <pre><code>#ifndef SPACE_HPP_INCLUDED
  #define SPACE_HPP_INCLUDED
  namespace ns
  {
     class player
     {
        private:
           int stat1, stat2, stat3;
        public:
           player();
           player(int, int, int);
     };
  }
  #endif
  </code></pre>
  
  <p>space.cpp</p>
  
  <pre><code>#include "space.hpp"
  ns::player::player()
  {
     stat1 = 100;
     stat2 = 200;
     stat3 = 300;
  }
  ns::player::player(int a, int b, int c)
  {
     stat1 = a;
     stat2 = b;
     stat3 = c;
  }
  </code></pre>