title: position.hh:46: error: expected unqualified-id before ‘namespace’
body: <p>Here's my code:</p>
  
  <pre><code> 34  
   35 /**  
   36  ** \file position.hh  
   37  ** Define the example::position class.  
   38  */  
   39   
   40 #ifndef BISON_POSITION_HH   
   41 #define BISON_POSITION_HH   
   42    
   43 #include &lt;iostream&gt;   
   44 #include &lt;string&gt;   
   45    
   46 namespace example   
   47 {   
   48   /// Abstract a position.   
   49   class position   
   50   {   
   51   public:   
   52    
   53     /// Construct a position.   
   54     position ()    
   55       : filename (0), line (1), column (0)   
   56     {    
  </code></pre>
  
  <p>Thanks, speeder, that's great. Necrolis, thank you as well. Both of you guys are onto the same track on the compilation units. Here's the full error report:</p>
  
  <p>In file included from location.hh:45,
                   from parser.h:64,
                   from scanner.h:25,
                   from scanner.ll:8:
  position.hh:46: error: expected unqualified-id before ‘namespace’</p>
  
  <p>location.hh looks like this:</p>
  
  <pre><code>35 /**
  36  ** \file location.hh
  37  ** Define the example::location class.
  38  */
  39 
  40 #ifndef BISON_LOCATION_HH
  41 # define BISON_LOCATION_HH
  42 
  43 # include &lt;iostream&gt;
  44 # include &lt;string&gt;
  45 # include "position.hh"
  46 
  47 namespace example
  48 {
  49 
  50   /// Abstract a location.
  51   class location
  52   {
  53   public:
  </code></pre>
  
  <p>I should also add that these files are being generated by bison. it's when i try to compile the c++ scanner class generated by flex++ that I get to this stage. I get the .cc code by issuing flex --c++ -o scanner.cc scanner.ll.</p>