JavaScript:SpiderMonkey:C++ Coding Style: Difference between revisions

Add style for inlines ordering.
(Add info about conditionals.)
(Add style for inlines ordering.)
Line 6: Line 6:


C++ is powerful, with many degrees of freedom and some attractive nuisances. We should aspire to use it in a lean, close-to-the-metal fashion, and avoid style-over-substance [http://www.bikeshed.com/ bikeshedding].
C++ is powerful, with many degrees of freedom and some attractive nuisances. We should aspire to use it in a lean, close-to-the-metal fashion, and avoid style-over-substance [http://www.bikeshed.com/ bikeshedding].
== Includes ==
The following order is used for includes:
#include "jsbar.h"
#include "jsfoo.h"
#include "ds/Baz.h"
#include "vm/Bat.h"
#include "jswoot-inl.h"
#include "jssquee-inl.h"
#include "frontend/Thingamabob-inl.h"
#include "vm/VirtualReality-inl.h"
Including X-inl.h implies that X.h is included as well.


== Conditionals ==
== Conditionals ==
29

edits