How to include <algorithm> header of stl in gcc?

Marc Glisse
Thu Feb 20 12:33:00 GMT 2014

On Thu, 20 Feb 2014, Pritam Gharat wrote:

>   I am using sets of stl in gcc. I need to perform operations like set 
> union, set intersection and set difference for my analysis. These functions 
> are defined in the header <algorithm>. However, when I include this header in 
> my file, I get the following error:
> /home/pritam/GCC_BUILDS/gcc_4.7/install/lib/gcc/i686-pc-linux-gnu/4.7.2/../../../../include/c++/4.7.2/cstdlib:76:8: 
> error: attempt to use poisoned "calloc"

Include <algorithm> before any gcc header, i.e. before things can be 

Marc Glisse

More information about the Gcc mailing list