From 03e6c9859c4d2ab66377aaf48dbf84456938e4e7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vladim=C3=ADr=20Vondru=C5=A1?= Date: Mon, 19 Nov 2012 19:28:29 +0100 Subject: [PATCH] Mention forward declarations and headers in coding style. --- doc/coding-style.dox | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/doc/coding-style.dox b/doc/coding-style.dox index 74ea08d2b..81c6a7a10 100644 --- a/doc/coding-style.dox +++ b/doc/coding-style.dox @@ -29,6 +29,15 @@ When writing wrappers for OpenGL functions and defines, try to match the original name as closely as possible, although expanding abbrevations (and removing redundant prefixes) is encouraged. +@subsubsection cpp-forward-declarations Forward declarations and forward declaration headers + +Use forward declarations in headers as much as possible, as it can +significantly reduce time of incremental compilation. When an namespace has +classes which are commonly forward-declared, consider making a forward +declaration header - it should have the same name as the namespace itself and +contain foward declarations for all classes, enums and copies of all +meaningful typedefs. See SceneGraph/SceneGraph.h for an example. + @section documentation Doxygen documentation @subsection documentation-commands Special documentation commands