#include <boost/shared_ptr.hpp> or #include "boost/shared_ptr.hpp"?

#include <boost/shared_ptr.hpp> or #include "boost/shared_ptr.hpp"?

Post by Colin Caug » Wed, 30 Aug 2006 18:04:23


Is there a general rule/convention for when to use angle brackets and
when to use quotes in #include statements? Is the angle bracket reserved
for "system" header files (e.g. standard library headers), or is it for
general "stable" include files?

What about the grey areas in between these and actual application code,
e.g. headers for a library that is under my control but external to the
project being compiled?

I know both styles work, and in the case of the Boost headers I've seen
both of them used in example code, I'm just wondering if one is more
"correct"?

Cheers,
Colin
 
 
 

#include <boost/shared_ptr.hpp> or #include "boost/shared_ptr.hpp"?

Post by Shootin » Wed, 30 Aug 2006 23:19:52

<>will search the system folder and project/IDE specified additional
include dictionary
"" will search in your project dictionary