Re: [Gc] Recompiling libgc 7.1

Ivan Maidanski ivmai at mail.ru
Thu Dec 11 10:56:01 PST 2008


Hi!

Christophe Meessen <meessen at cppm.in2p3.fr> wrote:
> 
> Hello,
> 
> my laptop crashed and I had to reinstall libgc 7.1 on it. I decided to 
> reinstall it from scratch, as a new user, to check if I had any problems.
> The compiler is VC++ express 2008 (thus version 9 of  VC++).
> 
> I'm using NT_STATIC_THREADS_MAKEFILE and I get the following warning in 
> some files.
> 
> 1>c:\program files\microsoft visual studio 9.0\vc\include\new(82) : 
> warning C4985: 'operator new[]' : attributs absents de la dИclaration 
> prИcИdente.
> 1>        f:\christophe\sources\gc-7.1\include\gc_cpp.h(252) : voir la 
> dИclaration de 'operator new[]'
> 1>c:\program files\microsoft visual studio 9.0\vc\include\crtdbg.h(1170) 
> : warning C4985: 'operator new' : attributs absents de la dИclaration 
> prИcИdente.
> 1>        f:\christophe\sources\gc-7.1\include\gc_cpp.h(261) : voir la 
> dИclaration de 'operator new'
> 
> This is how I include libgc
> #define GC_THREADS
> #include "gc_cpp.h"
> #include "gc_allocator.h"

Here I'm getting only the first warning (with VC++ 2008) with gc71 (and with the latest CVS).

> 
> If I swap include order, the first warning disappear.

That's because gc_cpp.h doesn't include <new> for now.
In my opinion, gc_cpp.h (in CVS) should be fixed to include it.

> 
> 
> I also had allot of problems earlier with STL and GC. I had to use the 
> gc_allocator with STL containers to make sure their content gets collected.
> It might be related to the previous problem.

What are these problems?

> 
> Any clue how this should be resolved ?

My first suggestion - try the latest (7.2a1) version of GC (from CVS).

Bye.



More information about the Gc mailing list