Confirmed users
1,345
edits
Nnethercote (talk | contribs) |
Nnethercote (talk | contribs) |
||
Line 24: | Line 24: | ||
== Includes == | == Includes == | ||
The following order is used for includes: the module's .h (this ensures it includes all the headers it needs itself), mozilla/*.h; | The following order is used for includes: the module's .h (this ensures it includes all the headers it needs itself), mozilla/*.h; <*.h>, js*.h; */*.h; js*inlines.h and js*-inl.h; */*-inl.h. The public JSAPI headers in js/public/*.h should be included as js/*.h in the */*.h block. | ||
Example for jsfoo.cpp: | Example for jsfoo.cpp: | ||
#include "jsfoo.h" | #include "jsfoo.h" | ||
#include "mozilla/StdInt.h" | #include "mozilla/StdInt.h" | ||
#include <string.h> | #include <string.h> | ||