1 This file documents some conventions for sorting system header files in
4 1. #include <config.h> unconditionally
6 2. if there are any headers containing "alloca" in the name, include
7 them here. Some systems need them as the first header.
9 3. #include the Standard C Library headers, sorted alphabetically
11 (assert, ctype, errno, float, limits, locale, math, setjmp, signal,
12 stdarg, stddef, stdio, stdlib, string, time)
14 4. #include the POSIX headers, in the following order
16 <sys/types.h> Needed by many other headers.
20 For every POSIX function you use, make sure that the order of the
21 headers is the same as in the according manpage.
23 5. #include other external headers
25 6. #include "../src/global.h"
27 This file contains lots of compatibility stuff that is used
28 throughout the whole mc. All mc header files rely on this file to be
31 7. #include Midnight Commander headers
33 Currently, not all headers can be ordered arbitrarily, so try it out.
36 ==== Headers that may be included unconditionally ====
45 ==== Headers that need autoconf guards ====