summaryrefslogtreecommitdiffstats
path: root/Source/cmSourceFile.cxx
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2016-05-06 18:30:06 (GMT)
committerBrad King <brad.king@kitware.com>2016-05-09 13:41:43 (GMT)
commit0ac18d40c8c29a17f1acfcaca506f41a26185901 (patch)
tree88b5d3c4b8c587d7979231d0e6ce9b03b0685a74 /Source/cmSourceFile.cxx
parentd95fbdb70944a8f9a7e6ac11bc51f410a99aafcd (diff)
downloadCMake-0ac18d40c8c29a17f1acfcaca506f41a26185901.zip
CMake-0ac18d40c8c29a17f1acfcaca506f41a26185901.tar.gz
CMake-0ac18d40c8c29a17f1acfcaca506f41a26185901.tar.bz2
Remove `//------...` horizontal separator comments
Modern editors provide plenty of ways to visually separate functions. Drop the explicit comments that previously served this purpose. Use the following command to automate the change: $ git ls-files -z -- \ "*.c" "*.cc" "*.cpp" "*.cxx" "*.h" "*.hh" "*.hpp" "*.hxx" | egrep -z -v "^Source/cmCommandArgumentLexer\." | egrep -z -v "^Source/cmCommandArgumentParser(\.y|\.cxx|Tokens\.h)" | egrep -z -v "^Source/cmDependsJavaLexer\." | egrep -z -v "^Source/cmDependsJavaParser(\.y|\.cxx|Tokens\.h)" | egrep -z -v "^Source/cmExprLexer\." | egrep -z -v "^Source/cmExprParser(\.y|\.cxx|Tokens\.h)" | egrep -z -v "^Source/cmFortranLexer\." | egrep -z -v "^Source/cmFortranParser(\.y|\.cxx|Tokens\.h)" | egrep -z -v "^Source/cmListFileLexer\." | egrep -z -v "^Source/cm_sha2" | egrep -z -v "^Source/(kwsys|CursesDialog/form)/" | egrep -z -v "^Utilities/(KW|cm).*/" | xargs -0 sed -i '/^\(\/\/---*\|\/\*---*\*\/\)$/ {d;}' This avoids modifying third-party sources and generated sources.
Diffstat (limited to 'Source/cmSourceFile.cxx')
-rw-r--r--Source/cmSourceFile.cxx23
1 files changed, 0 insertions, 23 deletions
diff --git a/Source/cmSourceFile.cxx b/Source/cmSourceFile.cxx
index a9ac549..b31bc74 100644
--- a/Source/cmSourceFile.cxx
+++ b/Source/cmSourceFile.cxx
@@ -16,7 +16,6 @@
#include "cmSystemTools.h"
#include "cmake.h"
-//----------------------------------------------------------------------------
cmSourceFile::cmSourceFile(cmMakefile* mf, const std::string& name):
Location(mf, name)
{
@@ -26,13 +25,11 @@ cmSourceFile::cmSourceFile(cmMakefile* mf, const std::string& name):
cmSystemTools::GetFilenameLastExtension(this->Location.GetName()));
}
-//----------------------------------------------------------------------------
cmSourceFile::~cmSourceFile()
{
this->SetCustomCommand(0);
}
-//----------------------------------------------------------------------------
std::string const& cmSourceFile::GetExtension() const
{
return this->Extension;
@@ -40,19 +37,16 @@ std::string const& cmSourceFile::GetExtension() const
const std::string cmSourceFile::propLANGUAGE = "LANGUAGE";
-//----------------------------------------------------------------------------
void cmSourceFile::SetObjectLibrary(std::string const& objlib)
{
this->ObjectLibrary = objlib;
}
-//----------------------------------------------------------------------------
std::string cmSourceFile::GetObjectLibrary() const
{
return this->ObjectLibrary;
}
-//----------------------------------------------------------------------------
std::string cmSourceFile::GetLanguage()
{
// If the language was set explicitly by the user then use it.
@@ -89,7 +83,6 @@ std::string cmSourceFile::GetLanguage()
return static_cast<cmSourceFile const*>(this)->GetLanguage();
}
-//----------------------------------------------------------------------------
std::string cmSourceFile::GetLanguage() const
{
// If the language was set explicitly by the user then use it.
@@ -108,13 +101,11 @@ std::string cmSourceFile::GetLanguage() const
return "";
}
-//----------------------------------------------------------------------------
cmSourceFileLocation const& cmSourceFile::GetLocation() const
{
return this->Location;
}
-//----------------------------------------------------------------------------
std::string const& cmSourceFile::GetFullPath(std::string* error)
{
if(this->FullPath.empty())
@@ -127,13 +118,11 @@ std::string const& cmSourceFile::GetFullPath(std::string* error)
return this->FullPath;
}
-//----------------------------------------------------------------------------
std::string const& cmSourceFile::GetFullPath() const
{
return this->FullPath;
}
-//----------------------------------------------------------------------------
bool cmSourceFile::FindFullPath(std::string* error)
{
// If thie method has already failed once do not try again.
@@ -232,7 +221,6 @@ bool cmSourceFile::FindFullPath(std::string* error)
return false;
}
-//----------------------------------------------------------------------------
bool cmSourceFile::TryFullPath(const std::string& path,
const std::string& ext)
{
@@ -250,7 +238,6 @@ bool cmSourceFile::TryFullPath(const std::string& path,
return false;
}
-//----------------------------------------------------------------------------
void cmSourceFile::CheckExtension()
{
// Compute the extension.
@@ -277,7 +264,6 @@ void cmSourceFile::CheckExtension()
}
}
-//----------------------------------------------------------------------------
void cmSourceFile::CheckLanguage(std::string const& ext)
{
// Try to identify the source file language from the extension.
@@ -290,13 +276,11 @@ void cmSourceFile::CheckLanguage(std::string const& ext)
}
}
-//----------------------------------------------------------------------------
bool cmSourceFile::Matches(cmSourceFileLocation const& loc)
{
return this->Location.Matches(loc);
}
-//----------------------------------------------------------------------------
void cmSourceFile::SetProperty(const std::string& prop, const char* value)
{
this->Properties.SetProperty(prop, value);
@@ -311,14 +295,12 @@ void cmSourceFile::SetProperty(const std::string& prop, const char* value)
}
}
-//----------------------------------------------------------------------------
void cmSourceFile::AppendProperty(const std::string& prop, const char* value,
bool asString)
{
this->Properties.AppendProperty(prop, value, asString);
}
-//----------------------------------------------------------------------------
const char* cmSourceFile::GetPropertyForUser(const std::string& prop)
{
// This method is a consequence of design history and backwards
@@ -345,7 +327,6 @@ const char* cmSourceFile::GetPropertyForUser(const std::string& prop)
return this->GetProperty(prop);
}
-//----------------------------------------------------------------------------
const char* cmSourceFile::GetProperty(const std::string& prop) const
{
// Check for computed properties.
@@ -376,25 +357,21 @@ const char* cmSourceFile::GetProperty(const std::string& prop) const
return retVal;
}
-//----------------------------------------------------------------------------
bool cmSourceFile::GetPropertyAsBool(const std::string& prop) const
{
return cmSystemTools::IsOn(this->GetProperty(prop));
}
-//----------------------------------------------------------------------------
cmCustomCommand* cmSourceFile::GetCustomCommand()
{
return this->CustomCommand;
}
-//----------------------------------------------------------------------------
cmCustomCommand const* cmSourceFile::GetCustomCommand() const
{
return this->CustomCommand;
}
-//----------------------------------------------------------------------------
void cmSourceFile::SetCustomCommand(cmCustomCommand* cc)
{
cmCustomCommand* old = this->CustomCommand;