refactoring: Increased constness of function parameters

This commit is contained in:
Daniel Marjamäki 2008-12-06 07:40:13 +00:00
parent 345a7f2c9b
commit 6d7a0e65b3
4 changed files with 4 additions and 4 deletions

View File

@ -62,7 +62,7 @@ void CppCheck::addFile( const std::string &path, const std::string &content )
_fileContents[ path ] = content;
}
std::string CppCheck::parseFromArgs( int argc, char* argv[] )
std::string CppCheck::parseFromArgs( int argc, const char* argv[] )
{
std::vector<std::string> pathnames;
bool Recursive = false;

View File

@ -89,7 +89,7 @@ class CppCheck : public ErrorLogger
* string containing "help" text if no files were found to be
* checked.
*/
std::string parseFromArgs( int argc, char* argv[] );
std::string parseFromArgs( int argc, const char* argv[] );
private:
void checkFile(const std::string &code, const char FileName[]);

View File

@ -30,7 +30,7 @@ CppCheckExecutor::~CppCheckExecutor()
//dtor
}
void CppCheckExecutor::check( int argc, char* argv[] )
void CppCheckExecutor::check( int argc, const char* argv[] )
{
CppCheck cppCheck( *this );
std::string result = cppCheck.parseFromArgs( argc, argv );

View File

@ -47,7 +47,7 @@ public:
* @param argc from main()
* @param argv from main()
*/
void check( int argc, char* argv[] );
void check( int argc, const char* argv[] );
/**
* Errors and warnings are directed here. This should be