MyNixOS website logo
Description

Analyze #includes in C/C++ source files with clang.

For every symbol (type, function variable, or macro) that you use in foo.cc, either foo.cc or foo.h should #include a .h file that exports the declaration of that symbol. The main goal of include-what-you-use is to remove superfluous #includes, both by figuring out what #includes are not actually needed for this file (for both .cc and .h files), and by replacing #includes with forward-declares when possible.

Metadata

Version

0.21

Executables (2)

  • bin/fix_includes.py
  • bin/include-what-you-use

Platforms (44)

    Darwin
    FreeBSD 13
    Linux
    NetBSD
    OpenBSD
    Redox
    Solaris
    Windows
Show all
  • aarch64-darwin
  • aarch64-linux
  • aarch64-netbsd
  • armv5tel-linux
  • armv6l-linux
  • armv6l-netbsd
  • armv7a-darwin
  • armv7a-linux
  • armv7a-netbsd
  • armv7l-linux
  • armv7l-netbsd
  • i686-cygwin
  • i686-darwin
  • i686-freebsd13
  • i686-linux
  • i686-netbsd
  • i686-openbsd
  • loongarch64-linux
  • m68k-linux
  • m68k-netbsd
  • microblaze-linux
  • microblazeel-linux
  • mips-linux
  • mips64-linux
  • mips64el-linux
  • mipsel-linux
  • mipsel-netbsd
  • powerpc-netbsd
  • powerpc64-linux
  • powerpc64le-linux
  • riscv32-linux
  • riscv32-netbsd
  • riscv64-linux
  • riscv64-netbsd
  • s390-linux
  • s390x-linux
  • x86_64-cygwin
  • x86_64-darwin
  • x86_64-freebsd13
  • x86_64-linux
  • x86_64-netbsd
  • x86_64-openbsd
  • x86_64-redox
  • x86_64-solaris