New Krazy Check: cpp macros

Allen Winter winter at kde.org
Tue Jun 19 17:29:44 BST 2007


Howdy,

Tonight I plan to install a new Krazy check for cpp stuff we don't
want to have in our code.

Currently it only tests for O/S and compiler specific macros.
eg.
we don't want  #if (__sgi) to test if header foo.h should be included.
rather, we want  #if (HAVE_FOO_H)

Oh, but I don't check in installed headers because they
can't have <config-pkg.h> includes.

As usual, you can tell Krazy to ignore by using //krazy:exclude=cpp

IOW: it checks for these.  Please let me know what I missed.
  Q_OS_*
  _WIN32
  _WIN64
  __APPLE__
  __svr4__
  __linux__
  __bsdi__
  __FreeBSD__
  __NetBSD__
  __OpenBSD__
  __DragonFly__
  __GNU__
  __osf__
  __hpux
  __sun
  __sgi
  __CYGWIN__

  Q_CC_*
__GNUC__
__BORLANDC__





More information about the kde-core-devel mailing list