Skip to content

Commit

Permalink
STYLE: Remove this-> when ParameterFileParser accesses its own data
Browse files Browse the repository at this point in the history
The prefix `this->` is not necessary when a class just accesses its own private data.
  • Loading branch information
N-Dekker committed Jan 30, 2025
1 parent 00cd2a5 commit 9a00bb5
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions Common/ParameterFileParser/itkParameterFileParser.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -322,7 +322,7 @@ ParameterFileParser ::~ParameterFileParser() = default;
const ParameterFileParser::ParameterMapType &
ParameterFileParser::GetParameterMap() const
{
return this->m_ParameterMap;
return m_ParameterMap;

} // end GetParameterMap()

Expand All @@ -338,12 +338,12 @@ ParameterFileParser::ReadParameterFile()
BasicFileChecking(m_ParameterFileName);

/** Open the parameter file for reading. */
std::ifstream parameterFile(this->m_ParameterFileName);
std::ifstream parameterFile(m_ParameterFileName);

/** Check if it opened. */
if (!parameterFile.is_open())
{
itkExceptionMacro("ERROR: could not open " << this->m_ParameterFileName << " for reading.");
itkExceptionMacro("ERROR: could not open " << m_ParameterFileName << " for reading.");
}

ReadParameterMapFromInputStream(m_ParameterMap, parameterFile);
Expand All @@ -362,12 +362,12 @@ ParameterFileParser::ReturnParameterFileAsString()
BasicFileChecking(m_ParameterFileName);

/** Open the parameter file for reading. */
std::ifstream parameterFile(this->m_ParameterFileName);
std::ifstream parameterFile(m_ParameterFileName);

/** Check if it opened. */
if (!parameterFile.is_open())
{
itkExceptionMacro("ERROR: could not open " << this->m_ParameterFileName << " for reading.");
itkExceptionMacro("ERROR: could not open " << m_ParameterFileName << " for reading.");
}

/** Loop over the parameter file, line by line. */
Expand Down

0 comments on commit 9a00bb5

Please sign in to comment.