Просмотр исходного кода

KWSys 2016-03-29 (b51abb30)

Code extracted from:

    http://public.kitware.com/KWSys.git

at commit b51abb307d3b40957cc508aa54d449d9b41f5537 (master).

Upstream Shortlog
-----------------

Ben Boeckel (1):
      069a6b37 windows: check for _WIN32 rather than WIN32

Felix Geyer (1):
      b51abb30 SystemInformation: Fix spelling typos in comments
KWSys Upstream 9 лет назад
Родитель
Сommit
735c41ddb0
4 измененных файлов с 8 добавлено и 8 удалено
  1. 1 1
      RegularExpression.cxx
  2. 2 2
      RegularExpression.hxx.in
  3. 4 4
      SystemInformation.cxx
  4. 1 1
      testEncoding.cxx

+ 1 - 1
RegularExpression.cxx

@@ -376,7 +376,7 @@ bool RegularExpression::compile (const char* exp) {
     }
 
     // Allocate space.
-//#ifndef WIN32
+//#ifndef _WIN32
     if (this->program != 0) delete [] this->program;
 //#endif
     this->program = new char[regsize];

+ 2 - 2
RegularExpression.hxx.in

@@ -333,7 +333,7 @@ inline RegularExpression::RegularExpression (const std::string& s)
  */
 inline RegularExpression::~RegularExpression () 
 {
-//#ifndef WIN32
+//#ifndef _WIN32
   delete [] this->program;
 //#endif
 }
@@ -396,7 +396,7 @@ inline bool RegularExpression::is_valid () const
 
 inline void RegularExpression::set_invalid () 
 {
-//#ifndef WIN32
+//#ifndef _WIN32
   delete [] this->program;
 //#endif
   this->program = 0;

+ 4 - 4
SystemInformation.cxx

@@ -1583,7 +1583,7 @@ SystemInformationImplementation::~SystemInformationImplementation()
 
 void SystemInformationImplementation::RunCPUCheck()
 {
-#ifdef WIN32
+#ifdef _WIN32
   // Check to see if this processor supports CPUID.
   bool supportsCPUID = DoesCPUSupportCPUID();
 
@@ -2056,7 +2056,7 @@ bool SystemInformationImplementation::DoesCPUSupportFeature(long int dwFeature)
 
 void SystemInformationImplementation::Delay(unsigned int uiMS)
 {
-#ifdef WIN32
+#ifdef _WIN32
   LARGE_INTEGER Frequency, StartCounter, EndCounter;
   __int64 x;
 
@@ -2339,7 +2339,7 @@ bool SystemInformationImplementation::RetrieveClassicalCPUCacheDetails()
         case 13: TLBCacheUnit = ((TLBCacheData[3] & 0x00FF0000) >> 16); break;
         case 14: TLBCacheUnit = ((TLBCacheData[3] & 0xFF000000) >> 24); break;
 
-        // Default case - an error has occured.
+        // Default case - an error has occurred.
         default: return false;
         }
 
@@ -2401,7 +2401,7 @@ bool SystemInformationImplementation::RetrieveClassicalCPUCacheDetails()
         case 0x96: STORE_TLBCACHE_INFO (TLBCode, 262144); break;  // <-- FIXME: IA-64 Only
         case 0x9b: STORE_TLBCACHE_INFO (TLBCode, 262144); break;  // <-- FIXME: IA-64 Only
 
-        // Default case - an error has occured.
+        // Default case - an error has occurred.
         default: return false;
         }
       }

+ 1 - 1
testEncoding.cxx

@@ -120,7 +120,7 @@ static int testRobustEncoding()
     ret++;
     }
 
-#ifdef WIN32
+#ifdef _WIN32
   // 16 bit wchar_t - we make an invalid surrogate pair
   wchar_t cwstr[] = {0xD801, 0xDA00, 0};
   // this conversion could fail