xref: /linux/tools/perf/.clang-format (revision 3d5e48944e824bddc20d7b874e784f7b279636fe)
1*b5050b13SIan RogersBasedOnStyle: InheritParentConfig
2*b5050b13SIan RogersSortIncludes: true
3*b5050b13SIan RogersIncludeBlocks: Regroup
4*b5050b13SIan RogersIncludeCategories:
5*b5050b13SIan Rogers  # Implicitly the corresponding header for the C file has Priority 0
6*b5050b13SIan Rogers  # C Standard Library Headers
7*b5050b13SIan Rogers  - Regex:           '^<(assert|complex|ctype|errno|fenv|float|inttypes|iso646|limits|locale|math|setjmp|signal|stdalign|stdarg|stdatomic|stdbool|stddef|stdint|stdio|stdlib|stdnoreturn|string|tgmath|threads|time|uchar|wchar|wctype)\.h>'
8*b5050b13SIan Rogers    Priority:        1
9*b5050b13SIan Rogers  # OS/System-Specific Headers (directories)
10*b5050b13SIan Rogers  - Regex:           '^<(sys|linux|asm|arpa|net|netinet|x86_64|machine)/.*>'
11*b5050b13SIan Rogers    Priority:        2
12*b5050b13SIan Rogers  # OS/System-Specific Headers (POSIX/System flat headers)
13*b5050b13SIan Rogers  - Regex:           '^<(unistd|pthread|fcntl|dirent|dlfcn|poll|sched|semaphore|spawn|syslog|termios|pwd|grp|netdb|sysexits|err|paths|pty|utmp|resolv|ifaddrs|elf|libelf|gelf)\.h>'
14*b5050b13SIan Rogers    Priority:        2
15*b5050b13SIan Rogers  # Third-Party Library Headers
16*b5050b13SIan Rogers  - Regex:           '^<.*>'
17*b5050b13SIan Rogers    Priority:        3
18*b5050b13SIan Rogers  # Your Project's Other Headers
19*b5050b13SIan Rogers  - Regex:           '^".*"'
20*b5050b13SIan Rogers    Priority:        4
21