471,047 Members | 1,255 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,047 software developers and data experts.

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

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
Aug 29 '06 #1
1 3910
<>will search the system folder and project/IDE specified additional
include dictionary
"" will search in your project dictionary

Colin Caughie wrote:
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
Aug 29 '06 #2

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

14 posts views Thread by Ernst Murnleitner | last post: by
11 posts views Thread by icanoop | last post: by
2 posts views Thread by Lionel B | last post: by
9 posts views Thread by PengYu.UT | last post: by
8 posts views Thread by timor.super | last post: by
19 posts views Thread by Daniel Pitts | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.