title: Why using namespace doesn't work in my C++ project?
body: <p>I after vast effort could (details are in here <a href="https://stackoverflow.com/questions/21063872/fltk-version-1-3-2-visual-studio-2012-and-the-first-example-of-stroustrups-ppp">FLTK version 1.3.2, Visual studio 2012 and the first example of Stroustrup&#39;s PPP book</a>) to ran the below code;</p>
  
  <pre><code>#include &lt;Simple_window.h&gt;    
  #include &lt;Graph.h&gt;  
  
  //*********************************************
  
  int main()
  {
      using namespace Graph_lib; 
  
      Point tl(100,100);
      Simple_window win(tl,600,400,"Canvas");
  
  
      Graph_lib::Polygon poly;
      poly.add(Point(300,200));
      poly.add(Point(350,100));
      poly.add(Point(400,200));
      win.attach(poly);
  
  
      win.set_label("Canvas");
      win.wait_for_button();   
  }
  </code></pre>
  
  <p>But for <code>Polygon poly;</code> I should use <code>Graph_lib::</code>, while since I have added the statement <code>using namespace Graph_lib;</code> at the top of the code's body (just below the <code>main</code> function) so there should not be any need to use the <code>Graph_lib::</code> for <em>Polygon</em>. But in effect without using it I get <em>ambiguous symbol</em> error. and also even I remove that statement (<code>using namespace Graph_lib;</code>) I don't get any error. My question is that why that statement doesn't work for that code and I have to use <code>Graph_lib::</code>?</p>