Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-1258

Do not redefine _WIN32

    • Type: Icon: Bug Bug
    • Resolution: Done
    • Priority: Icon: Critical - P2 Critical - P2
    • 1.5.5
    • Affects Version/s: None
    • Component/s: Build
    • None
    • Environment:
      Windows 7, 32 Bit
    • Windows

      Current nightly build e72597e.

      pch.h redefines _WIN32:

      #if defined(WIN32)
      // so you don't have to define this yourself as the code seems to use it...
      #undef _WIN32
      #define _WIN32
      #endif

      _WIN32 is a reserved symbol and should never be changes. This breaks e.g. compilation of Intels threading building blocks because they expect it to be defined as a number.

      See:
      http://predef.sourceforge.net/preos.html
      http://stackoverflow.com/questions/228783/what-are-the-rules-about-using-an-underscore-in-a-c-identifier

            Assignee:
            eliot Eliot Horowitz (Inactive)
            Reporter:
            languitar Johannes Wienke
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: