Possible Duplicate:
Is it a good idea to wrap an #include in a namespace block?
// Method One
#ifndef XXX_H
#define XXX_H
#include <iostream>
#include "myhead.h"
namespace XXX
{
/...
}
#endif
OR
// Method Two
namespace XXX
{
#ifndef XXX_H
#define XXX_H
#include <iostream>
#include "myhead.h"
/...
#endif
}
When we define a new namespace XXX
, should we move #include directive
inside namespace or not?
Thank you