Browse Source

COMP: fix some warnings and style issues

Ken Martin 19 years ago
parent
commit
1dd5db0235
4 changed files with 6 additions and 9 deletions
  1. 2 1
      Source/cmDocumentation.cxx
  2. 2 2
      Source/cmSetPropertiesCommand.cxx
  3. 2 1
      Source/cmTarget.cxx
  4. 0 5
      Source/cmake.cxx

+ 2 - 1
Source/cmDocumentation.cxx

@@ -580,7 +580,8 @@ void cmDocumentation::SetCommandsSection(const cmDocumentationEntry* section)
 }
 
 //----------------------------------------------------------------------------
-void cmDocumentation::SetPropertiesSection(const cmDocumentationEntry* section)
+void cmDocumentation
+::SetPropertiesSection(const cmDocumentationEntry* section)
 {
   this->SetSection(cmDocumentationPropertiesHeader, section, 0,
                    this->PropertiesSection);

+ 2 - 2
Source/cmSetPropertiesCommand.cxx

@@ -110,8 +110,8 @@ bool cmSetPropertiesCommand::InitialPass(
         std::string message = "Can not find target to add properties to: ";
         message += scopeName;
         this->SetError(message.c_str());
+        return ret;
         }
-      return ret;
       }
       break;
     case cmProperty::DIRECTORY:
@@ -146,8 +146,8 @@ bool cmSetPropertiesCommand::InitialPass(
       if (!ret)
         {
         this->SetError(errors.c_str());
+        return ret;
         }
-      return ret;
       }
       break;
     case cmProperty::SOURCE_FILE:

+ 2 - 1
Source/cmTarget.cxx

@@ -481,7 +481,8 @@ void cmTarget::TraceVSDependencies(std::string projFile,
             tLocation = cmSystemTools::GetFilenamePath(tLocation);
             std::string depLocation = cmSystemTools::GetFilenamePath(
               std::string(fullName));
-            depLocation = cmSystemTools::CollapseFullPath(depLocation.c_str());
+            depLocation = 
+              cmSystemTools::CollapseFullPath(depLocation.c_str());
             tLocation = cmSystemTools::CollapseFullPath(tLocation.c_str());
             if(depLocation == tLocation)
               {

+ 0 - 5
Source/cmake.cxx

@@ -2835,19 +2835,14 @@ bool cmake::IsPropertyDefined(const char *name, cmProperty::ScopeType scope)
     {
     case cmProperty::GLOBAL:
       return this->GlobalProperties.IsPropertyDefined(name);
-      break;
     case cmProperty::TARGET:
       return this->TargetProperties.IsPropertyDefined(name);
-      break;
     case cmProperty::SOURCE_FILE:
       return this->SourceFileProperties.IsPropertyDefined(name);
-      break;
     case cmProperty::DIRECTORY:
       return this->DirectoryProperties.IsPropertyDefined(name);
-      break;
     case cmProperty::TEST:
       return this->TestProperties.IsPropertyDefined(name);
-      break;
     }
 
   return false;