Soul-Engine icon indicating copy to clipboard operation
Soul-Engine copied to clipboard

Replace Includes With Forward Declarations

Open Behemyth opened this issue 8 years ago • 1 comments

Headers should not be included when a forward declaration suffices. If an #include is used for just a signature such as

  • void PushBack(const Dog$);
  • Dog* dog

and not as a storage requirement such as

  • Dog dog;

then the #include can be moved to the *.cpp file and a forward declaration used in its place class Dog;

Behemyth avatar Jul 27 '17 22:07 Behemyth