title: how does cout << actually work?
body: <p>I was wondering how <code>std::cout</code> is able to use <code>&lt;&lt;</code> as it does.</p>
  
  <p>My main puzzlement is with whether <code>std::cout</code> as an instance of something. Basically, how is <code>&lt;&lt;</code> defined? If I do this for a custom class, I need an instance of some sort...</p>
  
  <p>I could see implementing it as kind of a hack with void pointers or something, but I'd like to see the actual way it's done.</p>
  
  <p>Does anyone here know?
  Thanks</p>