The following code doesn't compile:

namespace foo {
#include <vector>
}

int main (void) {
  return 0;
}

Many errors follow, the first one looks like:

In file included 
from /sys/cadappl_linuxi386_borealis/gcc/3.3.3/include/c++/3.3.3/cstring:49,
                 
from /sys/cadappl_linuxi386_borealis/gcc/3.3.3/include/c++/3.3.3/bits/stl_algob
ase.h:65,
                 
from /sys/cadappl_linuxi386_borealis/gcc/3.3.3/include/c++/3.3.3/vector:67,
                 from map_test.cc:2:
/sys/cadappl_linuxi386_borealis/gcc/3.3.3/include/c++/3.3.3/cstddef:52: error: 
`
   ptrdiff_t' not declared
/sys/cadappl_linuxi386_borealis/gcc/3.3.3/include/c++/3.3.3/cstddef:53: error: 
`
   size_t' not declared

-- 
           Summary: Including STL headers in a namespace doesn't compile
           Product: gcc
           Version: 3.3.3
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: JurgenvonOerthel at hotmail dot com
                CC: gcc-bugs at gcc dot gnu dot org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19373

Reply via email to